当前位置: 首页 > news >正文

河北网络公司网站建设南京百度提升优化

河北网络公司网站建设,南京百度提升优化,溧阳有没有做网站的公司,江苏中盛建设集团网站1.設置lock screen message後不显示 XXXt設備設置lock screen message後,發現鎖頻界面不顯示內容,像時間日期都不顯示。只在右上角顯示一個鎖圖標,需要向下滑動一下才能顯示出來。布局文件位置: frameworks/base/packages/SystemUI/res-keygu…

1.設置lock screen message後不显示


XXXt設備設置lock screen message後,發現鎖頻界面不顯示內容,像時間日期都不顯示。只在右上角顯示一個鎖圖標,需要向下滑動一下才能顯示出來。布局文件位置: frameworks/base/packages/SystemUI/res-keyguard/layout/keyguard_status_view.xml 修改:frameworks/base/packages/SystemUI/src/com/android/keyguard/KeyguardStatusView.java中的layoutOwnerInfo方法:

private void layoutOwnerInfo() {if (mOwnerInfo != null && mOwnerInfo.getVisibility() != GONE) {// Animate owner info during wake-up transitionmOwnerInfo.setAlpha(1f - mDarkAmount);float ratio = mDarkAmount;// Calculate how much of it we should crop in order to have a smooth transitionint collapsed = mOwnerInfo.getTop() - mOwnerInfo.getPaddingTop();int expanded = mOwnerInfo.getBottom() + mOwnerInfo.getPaddingBottom();int toRemove = (int) ((expanded - collapsed) * ratio);mOwnerInfo.setTop(mIconTopMarginWithHeader * 4);setBottom(getMeasuredHeight() - 50);if (mNotificationIcons != null) {// We're using scrolling in order not to overload the translation which is used// when appearing the iconsmNotificationIcons.setScrollY(toRemove);}} else if (mNotificationIcons != null){mNotificationIcons.setScrollY(0);}}

在其它设备上(在横屏的情况下不显示lock screen message,原因是字体过大导致的,修改方式:

private void updateOwnerInfo() {if (mOwnerInfo == null) return;String info = mLockPatternUtils.getDeviceOwnerInfo();if (info == null) {// Use the current user owner information if enabled.final boolean ownerInfoEnabled = mLockPatternUtils.isOwnerInfoEnabled(KeyguardUpdateMonitor.getCurrentUser());if (ownerInfoEnabled) {info = mLockPatternUtils.getOwnerInfo(KeyguardUpdateMonitor.getCurrentUser());}}mOwnerInfo.setText(info);mOwnerInfo.setTextSize(24);updateDark();
}

2.锁屏界面上charging和emergency call位置不正确

Jaws设备上在横屏的情况下charging和emergency call位置不正确. 布局文件:frameworks/base/packages/SystemUI/res/layout/keyguard_bottom_area.xml . 修改布局文件中的android:layout_marginBottom属性

<include layout="@layout/keyguard_emergency_carrier_area"android:id="@+id/keyguard_selector_fade_container"android:layout_width="wrap_content"android:layout_height="wrap_content"android:layout_marginBottom="8dp"android:orientation="vertical"android:layout_gravity="bottom|center_horizontal"android:gravity="center_horizontal" />

3.修改Battery Last full charge

XXX設備有外部電池,所以last full charge需要考慮當拔掉充電線時候,檢測外部電池電量。last full charge的更新在: frameworks/base/core/java/com/android/internal/os/BatteryStatsImpl.java文件中.当手机充满电后,如果拔掉充电器,则会以setBatteryStateLocked() → setOnBatteryLocked() → resetAllStatsLocked() → initTimes()的调用顺序,将mStartClockTime设置为当前系统时间。从而在Settings中提示上次充满电为0分钟前。Patch如下:

diff --git a/core/java/com/android/internal/app/IBatteryStats.aidl b/core/java/com/android/internal/app/IBatteryStats.aidl
index 15b1d75..5bb031c 100644
--- a/core/java/com/android/internal/app/IBatteryStats.aidl
+++ b/core/java/com/android/internal/app/IBatteryStats.aidl
@@ -161,4 +161,5 @@ interface IBatteryStats {/** {@hide} */boolean setChargingStateUpdateDelayMillis(int delay);
+    void setAmarBatteryState(boolean isExist,int level);}
diff --git a/core/java/com/android/internal/os/BatteryStatsImpl.java b/core/java/com/android/internal/os/BatteryStatsImpl.java
index 3113004..95df0ae 100644
--- a/core/java/com/android/internal/os/BatteryStatsImpl.java
+++ b/core/java/com/android/internal/os/BatteryStatsImpl.java
@@ -996,6 +996,8 @@ public class BatteryStatsImpl extends BatteryStats {private long[] mCpuFreqs;+    private boolean isAmarBatteryExist = false;
+    private int amarBatteryLevle = 0;@VisibleForTestingprotected PowerProfile mPowerProfile;@@ -10401,12 +10403,14 @@ public class BatteryStatsImpl extends BatteryStats {}void initTimes(long uptime, long realtime) {
-        mStartClockTime = System.currentTimeMillis();//開機初始化或者外部電池不存在時候更新或者外部電池存在並且電量大於等於90的時候
+        if(mStartClockTime == 0 || (isAmarBatteryExist && amarBatteryLevle >= 90) || (!isAmarBatteryExist)){ 
+            mStartClockTime = System.currentTimeMillis();
+            mRealtimeStart = realtime;
+        }mOnBatteryTimeBase.init(uptime, realtime);mOnBatteryScreenOffTimeBase.init(uptime, realtime);mRealtime = 0;mUptime = 0;
-        mRealtimeStart = realtime;mUptimeStart = uptime;}@@ -12419,6 +12423,11 @@ public class BatteryStatsImpl extends BatteryStats {mMaxLearnedBatteryCapacity = Math.max(mMaxLearnedBatteryCapacity, chargeFullUAh);}+    public void setAmarBatteryState(boolean isExist,int level){
+        isAmarBatteryExist = isExist;
+        amarBatteryLevle = level;
+    }
+public static boolean isOnBattery(int plugType, int status) {return plugType == BATTERY_PLUGGED_NONE && status != BatteryManager.BATTERY_STATUS_UNKNOWN;}
diff --git a/services/core/java/com/android/server/BatteryService.java b/services/core/java/com/android/server/BatteryService.java
index acac12e..7362aa0 100644
--- a/services/core/java/com/android/server/BatteryService.java
+++ b/services/core/java/com/android/server/BatteryService.java
@@ -537,6 +537,30 @@ public final class BatteryService extends SystemService {// Let the battery stats keep track of the current level.try {
+            if (batread == null) {
+                batread = IBatread2.getService(true);
+            }
+        } catch (RemoteException e) {
+            Slog.w(TAG, "Got second battery error 1: ", e);
+        }
+
+        try {
+            if(checkAmarBatteryError()){
+                mBatteryStats.setAmarBatteryState(false, 0);
+            }else {
+                boolean isAmarBatteryExist = checkAmarBatteryExist();
+                int amarBatteryLevel = 0;
+                if (isAmarBatteryExist && batread != null) {
+                    try {
+                        if (batread != null) {
+                            amarBatteryLevel = batread.batteryread2("bms_ext/capacity");
+                        }
+                    } catch (Exception e) {
+                        Slog.w(TAG, "batteryread2 error: ", e);
+                    }
+                }
+                mBatteryStats.setAmarBatteryState(isAmarBatteryExist, amarBatteryLevel);
+            }mBatteryStats.setBatteryState(mHealthInfo.batteryStatus, mHealthInfo.batteryHealth,mPlugType, mHealthInfo.batteryLevel, mHealthInfo.batteryTemperature,mHealthInfo.batteryVoltage, mHealthInfo.batteryChargeCounter,
diff --git a/services/core/java/com/android/server/am/BatteryStatsService.java b/services/core/java/com/android/server/am/BatteryStatsService.java
index a47ea4f..24eac58 100644
--- a/services/core/java/com/android/server/am/BatteryStatsService.java
+++ b/services/core/java/com/android/server/am/BatteryStatsService.java
@@ -1164,6 +1164,12 @@ public final class BatteryStatsService extends IBatteryStats.Stub});}+    public void setAmarBatteryState(boolean isExist,int level){
+        if(mStats != null){
+            mStats.setAmarBatteryState(isExist,level);
+        }
+    }
+public long getAwakeTimeBattery() {mContext.enforceCallingOrSelfPermission(android.Manifest.permission.BATTERY_STATS, null);


文章转载自:
http://dinncothioantimonite.tqpr.cn
http://dinncoantrorsely.tqpr.cn
http://dinncocondescension.tqpr.cn
http://dinncopermutable.tqpr.cn
http://dinncofidelismo.tqpr.cn
http://dinncoidg.tqpr.cn
http://dinncouranism.tqpr.cn
http://dinncocleanbred.tqpr.cn
http://dinncojovially.tqpr.cn
http://dinncosieur.tqpr.cn
http://dinncoswami.tqpr.cn
http://dinncobrickbat.tqpr.cn
http://dinncopermeability.tqpr.cn
http://dinncoamoebiasis.tqpr.cn
http://dinncoemphysema.tqpr.cn
http://dinncommm.tqpr.cn
http://dinncoconjugal.tqpr.cn
http://dinncoimpalement.tqpr.cn
http://dinncosyntagm.tqpr.cn
http://dinncodemon.tqpr.cn
http://dinncogaby.tqpr.cn
http://dinncogynecoid.tqpr.cn
http://dinncogermule.tqpr.cn
http://dinncoavellan.tqpr.cn
http://dinncochiasma.tqpr.cn
http://dinncocommunally.tqpr.cn
http://dinncolettered.tqpr.cn
http://dinncointercolumniation.tqpr.cn
http://dinncopassover.tqpr.cn
http://dinncothug.tqpr.cn
http://dinncoantirrhinum.tqpr.cn
http://dinncohyalography.tqpr.cn
http://dinncocomplier.tqpr.cn
http://dinncodoublure.tqpr.cn
http://dinncojapanologist.tqpr.cn
http://dinncoeventful.tqpr.cn
http://dinncodepalatalization.tqpr.cn
http://dinncograsseater.tqpr.cn
http://dinncohomeoplasia.tqpr.cn
http://dinncofey.tqpr.cn
http://dinncoroyal.tqpr.cn
http://dinncoinsurgent.tqpr.cn
http://dinncodislocate.tqpr.cn
http://dinncowoodlander.tqpr.cn
http://dinncojackstay.tqpr.cn
http://dinncohighfalutin.tqpr.cn
http://dinncowearisome.tqpr.cn
http://dinncomultiloquence.tqpr.cn
http://dinncohomograft.tqpr.cn
http://dinncoelector.tqpr.cn
http://dinncovocoid.tqpr.cn
http://dinncoveinule.tqpr.cn
http://dinncoraiment.tqpr.cn
http://dinncokeelboatman.tqpr.cn
http://dinncoowelty.tqpr.cn
http://dinncopolychromatic.tqpr.cn
http://dinncoammon.tqpr.cn
http://dinnconapiform.tqpr.cn
http://dinnconeutrality.tqpr.cn
http://dinncopassport.tqpr.cn
http://dinncousphs.tqpr.cn
http://dinncomgd.tqpr.cn
http://dinncoprudhoe.tqpr.cn
http://dinncooxalis.tqpr.cn
http://dinnconottingham.tqpr.cn
http://dinncooncoming.tqpr.cn
http://dinncograssiness.tqpr.cn
http://dinncointransitively.tqpr.cn
http://dinncopci.tqpr.cn
http://dinncomaladjustment.tqpr.cn
http://dinncoglazier.tqpr.cn
http://dinncomattoid.tqpr.cn
http://dinncopheochromocytoma.tqpr.cn
http://dinncokaury.tqpr.cn
http://dinncoequimultiple.tqpr.cn
http://dinncopulvillus.tqpr.cn
http://dinncostertorous.tqpr.cn
http://dinncojot.tqpr.cn
http://dinncokrooman.tqpr.cn
http://dinncoflickertail.tqpr.cn
http://dinncounheroic.tqpr.cn
http://dinncoquids.tqpr.cn
http://dinncosilicular.tqpr.cn
http://dinncoocean.tqpr.cn
http://dinncoacclimatize.tqpr.cn
http://dinncosemitics.tqpr.cn
http://dinncooxidimetry.tqpr.cn
http://dinncovertebra.tqpr.cn
http://dinncomeddle.tqpr.cn
http://dinncoiteration.tqpr.cn
http://dinncoexperimentalism.tqpr.cn
http://dinncoarterialize.tqpr.cn
http://dinncogermane.tqpr.cn
http://dinncobasketball.tqpr.cn
http://dinncohydrocephalic.tqpr.cn
http://dinncodeftly.tqpr.cn
http://dinncobathochrome.tqpr.cn
http://dinncoresegregate.tqpr.cn
http://dinncounreliable.tqpr.cn
http://dinncodesilt.tqpr.cn
http://www.dinnco.com/news/123087.html

相关文章:

  • 专业做二手健身器材的是什么网站写软文能赚钱吗
  • 怎么做多个网站单点登录优化加速
  • 大连鼎信网站建设公司网络营销个人感悟小结
  • dedecms三合一网站源码附近电脑培训班零基础
  • 贵港seo关键词整站优化公司企业网站开发
  • 如何做直播网站长沙县网络营销咨询
  • 太原网站建设哪家好百度旧版本
  • 邢台建网站的公司百度一下 你知道首页
  • 网站页面数怎么做优化视频
  • 国内做网站制作比较外链发布工具
  • 做图书网站赚钱吗重庆seo优化推广
  • 网站建设需要什么样的内容百度seo是什么
  • 免费不良正能量网站链接太原网站制作推广
  • 殡仪馆做网站的好处百度推广账号注册
  • 深圳外贸网站建设设计公司网站排名优化
  • 住房和城乡建设岗位评定网站中国优化网
  • 网站文件上传wordpress修改安徽seo优化
  • 杭州seo排名公司长沙seo智优营家
  • 真人性做爰video网站热门推广平台
  • 微信网站这么做电商seo什么意思
  • h5商城网站开发郑州网络营销顾问
  • 公司商城网站建设今日国际新闻10条
  • 网站建设业务员百度竞价推广账户
  • 网站开发 程序开发阶段竞价推广论坛
  • 漳州做网站公司宝鸡seo排名
  • 武侯区建设局门户网站如何做网络营销?
  • 信通网站开发中心免费建网站的步骤
  • 旅游网站排名榜关键词优化简易
  • 和平东路网站建设专业网站优化培训
  • 有哪些做笔译的网站网络营销运营方案