diff --git a/.classpath b/.classpath index 53da76b..0efb889 100644 --- a/.classpath +++ b/.classpath @@ -2,9 +2,9 @@ - - - + + + diff --git a/.project b/.project index 3260fa1..7066238 100644 --- a/.project +++ b/.project @@ -6,12 +6,12 @@ - org.eclipse.andmore.ResourceManagerBuilder + com.android.ide.eclipse.adt.ResourceManagerBuilder - org.eclipse.andmore.PreCompilerBuilder + com.android.ide.eclipse.adt.PreCompilerBuilder @@ -21,13 +21,13 @@ - org.eclipse.andmore.ApkBuilder + com.android.ide.eclipse.adt.ApkBuilder - org.eclipse.andmore.AndroidNature + com.android.ide.eclipse.adt.AndroidNature org.eclipse.jdt.core.javanature diff --git a/bin/com.pijulius.xposeddex.apk b/bin/com.pijulius.xposeddex.apk index dfed0ae..e8bb948 100644 Binary files a/bin/com.pijulius.xposeddex.apk and b/bin/com.pijulius.xposeddex.apk differ diff --git a/res/values/strings.xml b/res/values/strings.xml index c173c89..52ff27d 100644 --- a/res/values/strings.xml +++ b/res/values/strings.xml @@ -9,16 +9,14 @@ Will remove window titlebar for maximized applications. Fix Samsung Browser Enables secret mode and disable always visible scroll bar. + Fix SoundTouch + Make Bose SoundTouch app to be landscape and always show volume control slider. Dex Taskbar - Taskbar Fixes - Add small space above app docks running marker. Hide Tasks Button Removes the Tasks button from the taskbar. - Hide NoSIM Icon - Removes the NoSIM icon from statusbar. - Hide Battery Percentage - Removes the battery percentage from statusbar. + Hide Date + Removes the date from the taskbar below the clock. Hide Taskbar Separators Removes empty gaps (separators) from taskbar. diff --git a/res/xml/settings.xml b/res/xml/settings.xml index 6d48538..f8e6240 100644 --- a/res/xml/settings.xml +++ b/res/xml/settings.xml @@ -19,18 +19,18 @@ android:title="@string/settings_fix_sbrowser" android:key="fixSBrowser" /> + + - - - - + android:title="@string/settings_hide_date" + android:key="hideDate" /> hookClass = findClass("com.android.internal.policy.MultiWindowDecorSupport", + Class hookClass = findClass("com.android.internal.policy.DecorView", lpparam.classLoader); XposedBridge.hookAllMethods(hookClass, "isImmersiveMode", new XC_MethodHook() { @@ -67,9 +70,9 @@ public void taskbarResourceFixes(InitPackageResourcesParam resparam) { final boolean hideTasksButton = settings.getBoolean("hideTasksButton", true); final boolean hideTaskbarSeparators = settings.getBoolean("hideTaskbarSeparators", true); - final boolean spaceAboveAppDock = settings.getBoolean("fixTaskbar", true); + final boolean hideDate = settings.getBoolean("hideDate", true); - if (hideTasksButton || hideTaskbarSeparators || spaceAboveAppDock) { + if (hideTasksButton || hideTaskbarSeparators || hideDate) { resparam.res.hookLayout("com.samsung.desktopsystemui", "layout", "taskbar", new XC_LayoutInflated() { @Override public void handleLayoutInflated(XC_LayoutInflated.LayoutInflatedParam liparam) throws Throwable { @@ -111,70 +114,51 @@ public void handleLayoutInflated(XC_LayoutInflated.LayoutInflatedParam liparam) marginParams.setMarginEnd(0); } - if (spaceAboveAppDock) { + if (hideTasksButton && hideTaskbarSeparators) { view = (View)liparam.view.findViewById(liparam.res.getIdentifier( "appdock_container", "id", "com.samsung.desktopsystemui")); - view.setPadding(0, 4, 0, 0); + MarginLayoutParams marginParams = (MarginLayoutParams)view.getLayoutParams(); + marginParams.setMarginStart(400); + marginParams.setMarginEnd(550); } - } - }); - } - - if (settings.getBoolean("hideNoSIMIcon", true)) { - resparam.res.hookLayout("com.samsung.desktopsystemui", "layout", "desk_signal_cluster_view_25", new XC_LayoutInflated() { - @Override - public void handleLayoutInflated(XC_LayoutInflated.LayoutInflatedParam liparam) throws Throwable { - View view = null; - view = (View)liparam.view.findViewById(liparam.res.getIdentifier( - "no_sims_combo", "id", "com.samsung.desktopsystemui")); - - view.setVisibility(View.GONE); - view.getLayoutParams().width = 0; - - view = (View)liparam.view.findViewById(liparam.res.getIdentifier( - "sec_no_sim_slot1", "id", "com.samsung.desktopsystemui")); - - view.setVisibility(View.GONE); - view.getLayoutParams().width = 0; - - view = (View)liparam.view.findViewById(liparam.res.getIdentifier( - "sec_no_sim_slot2", "id", "com.samsung.desktopsystemui")); + if (hideDate) { + view = (View)liparam.view.findViewById(liparam.res.getIdentifier( + "date", "id", "com.samsung.desktopsystemui")); - view.setVisibility(View.GONE); - view.getLayoutParams().width = 0; + view.setVisibility(View.GONE); + view.getLayoutParams().width = 0; + view.setPadding(0, 0, 0, 0); + } } }); } - if (settings.getBoolean("hideBatteryPercentage", true)) { - resparam.res.hookLayout("com.samsung.desktopsystemui", "layout", "battery_percentage_view", new XC_LayoutInflated() { + if (hideTaskbarSeparators) { + resparam.res.hookLayout("com.samsung.desktopsystemui", "layout", "pinned_apps_divider", new XC_LayoutInflated() { @Override public void handleLayoutInflated(XC_LayoutInflated.LayoutInflatedParam liparam) throws Throwable { View view = null; - view = (View)liparam.view.findViewById(liparam.res.getIdentifier( - "battery_percentage_view", "id", "com.samsung.desktopsystemui")); + if (hideTaskbarSeparators) { + view = (View)liparam.view.findViewById(liparam.res.getIdentifier( + "pinned_apps_divider", "id", "com.samsung.desktopsystemui")); - view.setVisibility(View.GONE); + view.setVisibility(View.GONE); + view.getLayoutParams().width = 0; + view.setPadding(0, 0, 0, 0); + } } }); + } + } - resparam.res.hookLayout("com.samsung.desktopsystemui", "layout", "desk_system_icons", new XC_LayoutInflated() { - @Override - public void handleLayoutInflated(XC_LayoutInflated.LayoutInflatedParam liparam) throws Throwable { - View view = null; - - view = (View)liparam.view.findViewById(liparam.res.getIdentifier( - "system_icons_battery_container", "id", "com.samsung.desktopsystemui")); + public void soundtouchResourceFixes(InitPackageResourcesParam resparam) { + if (!resparam.packageName.equals("com.bose.soundtouch")) + return; - MarginLayoutParams marginParams = (MarginLayoutParams)view.getLayoutParams(); - marginParams.setMarginStart(10); - marginParams.setMarginEnd(10); - } - }); - } + resparam.res.setReplacement("com.bose.soundtouch", "bool", "allow_rotation", true); } public void sbrowserFixes(LoadPackageParam lpparam) { @@ -184,7 +168,7 @@ public void sbrowserFixes(LoadPackageParam lpparam) { Class hookClass = null; - hookClass = findClass("com.sec.android.app.sbrowser.SBrowserCommandLine", + hookClass = findClass("com.sec.android.app.sbrowser.init.SBrowserCommandLine", lpparam.classLoader); XposedBridge.hookAllMethods(hookClass, "setSamsungDexEnabled", new XC_MethodHook() {