[CM11][Port][XS]Smallapps/Taskswitcher guide

Search This thread

sidharth.gtm

Senior Member
May 11, 2012
222
395
Patna
Help needed ??

Just for curiosity .. if sswitch_2 is already taken by something else can ..

line 1397
:sswitch_2
const-string v0, "com.sony.smallapp.permission.SMALLAPP"

be replaced by :sswitch_3

and similarly for

0xbb5 -> :sswitch_3
0xbb6 -> :sswitch_3
 

Kevin-0100

Senior Member
Feb 16, 2013
124
70
Vlaardingen
Xperia XZ2
OnePlus 7T
Just for curiosity .. if sswitch_2 is already taken by something else can ..

line 1397
:sswitch_2
const-string v0, "com.sony.smallapp.permission.SMALLAPP"

be replaced by :sswitch_3

and similarly for

0xbb5 -> :sswitch_3
0xbb6 -> :sswitch_3

I don't think it will work, but you can always try it out:)

Sent from my C1905 using XDA Premium 4 mobile app
 
  • Like
Reactions: sidharth.gtm
Any idea what is cousing this?:
Code:
SmaliModule:ExecuteInternal | framework2 -> Assemble smali files: Assembling!
Script ExecuteScript | Executing framweork2 -> Assemble smali files fail!
Script ExecuteScript | Failed module is essential, aborting script execution!

Im getting on both Carbon-KK and CM11 when trying to build framework2.jar

EDIT: I dont have "com/android/systemui" and "com/android/systemui/recent" in my SystemUI? I dont have smali folder there if this is where it should be?
 
Last edited:
21:11:50.544: [Debug] - App.xaml.Application_Startup: 'Starting VTS'
21:11:50.552: [Debug] - App.xaml.Application_Startup: 'VTS version: 3.4.28.14000'
21:11:50.555: [Debug] - VTSIPC.IsVTSAlreadyRunning: 'This is the only running VTS instance right now'
21:11:50.596: [Debug] - VTSIPC.StartServer: 'Creating VTS mutex'
21:11:50.596: [Debug] - VTSIPC.StartServer: 'Starting IPC server'
21:11:50.755: [Debug] - ApkTool.LoadApkToolModels: 'Apktool search path: C:\Program Files (x86)\Virtuous Ten Studio\External\ApkTool\'
21:11:50.756: [Debug] - ApkTool.LoadApkToolModels: 'Found 2 apktool binaries'
21:11:50.757: [Debug] - ApkTool.ExecuteApkTool: 'ApkTool args: -version'
21:11:51.226: [Debug] - ApkTool.LoadApkToolModels: 'Found apktool with version: 1.5.2'
21:11:51.227: [Debug] - ApkTool.ExecuteApkTool: 'ApkTool args: -version'
21:11:51.332: [Debug] - ApkTool.LoadApkToolModels: 'Found apktool with version: 2.0.0'
21:11:51.337: [Debug] - ApkTool.SearchForFrameworkPath: 'Using ApkTool framework path: D:\ADMIN\apktool\framework'
21:11:51.342: [Debug] - SmaliTool.LoadSmaliModels: 'Smali search path: C:\Program Files (x86)\Virtuous Ten Studio\External\Smali\'
21:11:51.343: [Debug] - SmaliTool.LoadSmaliModels: 'Found 2 smali/baksmali binaries'
21:11:51.343: [Debug] - SmaliTool.GetSmaliVersion: 'Version args: -jar "C:\Program Files (x86)\Virtuous Ten Studio\External\Smali\smali-1.4.2.jar" -v'
21:11:51.496: [Debug] - SmaliTool.GetSmaliVersion: 'Version args: -jar "C:\Program Files (x86)\Virtuous Ten Studio\External\Smali\baksmali-1.4.2.jar" -v'
21:11:51.576: [Debug] - SmaliTool.LoadSmaliModels: 'Found smali/baksmali with version: 1.4.2'
21:11:51.577: [Debug] - SmaliTool.GetSmaliVersion: 'Version args: -jar "C:\Program Files (x86)\Virtuous Ten Studio\External\Smali\smali-2.0.3.jar" -v'
21:11:51.657: [Debug] - SmaliTool.GetSmaliVersion: 'Version args: -jar "C:\Program Files (x86)\Virtuous Ten Studio\External\Smali\baksmali-2.0.3.jar" -v'
21:11:51.740: [Debug] - SmaliTool.LoadSmaliModels: 'Found smali/baksmali with version: 2.0.3'
21:11:52.130: [Debug] - LicenseManager.GetLicense: 'Searching documents folder for license'

21:11:52.130: [Normal] - LicenseManager.GetLicense: 'No license file found, showing dialog'
21:11:52.148: [Debug] - RecentFilesViewModel.LoadRecentFilesFromSettings: 'Loading recent files, found 2'
21:11:55.007: [Debug] - Logger.LogPerformance: 'Startuptime: 4317ms'
21:11:55.342: [Debug] - PluginManager.LoadPluginAssemblies: 'Found 2 plugin assemblies'
21:11:55.369: [Debug] - PluginManager.LoadPluginAssemblies: 'Plugin 'Custom script - 1.4.28.933' by 'Diamondback' loaded'
21:11:55.369: [Debug] - PluginManager.LoadPluginAssemblies: 'No plugin info for plugin class: CustomScriptPlugin.Properties.Resources'
21:11:55.396: [Debug] - PluginManager.LoadPluginAssemblies: 'Plugin 'Auto solution loading - 1.4.28.1043' by 'Diamondback' loaded'
21:11:55.396: [Debug] - PluginManager.LoadPluginAssemblies: 'No plugin info for plugin class: OpenSolutionOnStartupPlugin.OpenSolutionOnStartupPluginClass+<>c__DisplayClass1'

21:12:05.179: [Normal] - UpdateChecker.SearchForUpdates: 'Searching for updates, beta: True'
21:12:25.487: [Normal] - WorkspaceViewModel.LoadSolution: 'Loading solution, path: D:\ADMIN\Moje dokumenty\Virtuous Ten Studio\Projects\carbon_zu\carbon_zu.tensln'
21:12:25.675: [Debug] - TenProjectViewModel.LoadBackups: 'Found 0 backups for project 'framework2''
21:12:25.675: [Debug] - TenProjectViewModel.LoadBackups: 'Found 0 backups for project 'framework-res''
21:12:25.675: [Debug] - TenProjectViewModel.LoadBackups: 'Found 0 backups for project 'android.policy''
21:12:25.678: [Debug] - TenProjectViewModel.LoadBackups: 'Found 0 backups for project 'SystemUI''
21:12:25.779: [Debug] - ResourceManager.LoadAnimationResources: 'No animations.xml available.'
21:12:25.782: [Debug] - ResourceManager.LoadColorResources: 'No dedicated color folder.'
21:12:25.814: [Debug] - ResourceManager.LoadAnimationResources: 'No animations.xml available.'

21:12:25.815: [Warning] - ResourceManager.Initialize: 'Error while analysing resources. Exception: Nazwa nie może rozpoczynać się od znaku '"' ani wartości szesnastkowej 0x22. wiersz 677, pozycja 74.'
21:12:29.645: [Normal] - TenProjectViewModel.BuildProject: 'Building project: framework2'
21:12:29.646: [Debug] - Script.ExecuteScript: 'Got 7 modules to execute'
21:12:29.647: [Normal] - BaseModule.Execute: 'Executing: framework2 -> Assign variable'
21:12:29.647: [Debug] - VariableModule.ExecuteInternal: 'framework2 -> Assign variable : Creating variable 'TmpBuildDir' with value '$(NewTmpPath())''
21:12:29.655: [Normal] - BaseModule.Execute: 'Executing: framework2 -> Copy files'
21:12:30.019: [Normal] - BaseModule.Execute: 'Executing: framework2 -> Assemble smali files'
21:12:30.022: [Normal] - SmaliTool.Smali: 'Compiling folder: D:\ADMIN\TEMP\user\DF5FD0\smali'
21:12:30.022: [Debug] - SmaliTool.Smali: 'Smali args: -Xmx512m -jar "C:\Program Files (x86)\Virtuous Ten Studio\External\Smali\smali-2.0.3.jar" --api-level 19 --output "D:\ADMIN\TEMP\user\DF5FD0\classes.dex" "D:\ADMIN\TEMP\user\DF5FD0\smali"'
21:12:32.077: [Debug] - SmaliTool.Smali: 'Smali: D:\ADMIN\TEMP\user\DF5FD0\smali\com\sony\smallapp\AbstractSmallApplication.smali[21,4] Error for input '.parameter': Invalid directive'
21:12:32.077: [Debug] - SmaliTool.Smali: 'Smali: D:\ADMIN\TEMP\user\DF5FD0\smali\com\sony\smallapp\internal\util\WindowUtils.smali[46,4] Error for input '.parameter': Invalid directive'
21:12:32.077: [Debug] - SmaliTool.Smali: 'Smali: D:\ADMIN\TEMP\user\DF5FD0\smali\com\sony\smallapp\internal\util\WindowUtils.smali[47,4] Error for input '.parameter': Invalid directive'
21:12:32.077: [Debug] - SmaliTool.Smali: 'Smali: D:\ADMIN\TEMP\user\DF5FD0\smali\com\sony\smallapp\AbstractSmallApplication.smali[21,15] mismatched input '"intent"' expecting END_METHOD_DIRECTIVE'
21:12:32.077: [Debug] - SmaliTool.Smali: 'Smali: D:\ADMIN\TEMP\user\DF5FD0\smali\com\sony\smallapp\internal\util\WindowUtils.smali[46,15] mismatched input '"context"' expecting END_METHOD_DIRECTIVE'
21:12:32.077: [Debug] - SmaliTool.Smali: 'Smali: D:\ADMIN\TEMP\user\DF5FD0\smali\com\sony\smallapp\internal\util\DialogHelper.smali[19,4] Error for input '.parameter': Invalid directive'
21:12:32.077: [Debug] - SmaliTool.Smali: 'Smali: D:\ADMIN\TEMP\user\DF5FD0\smali\com\sony\smallapp\internal\util\DialogHelper.smali[20,4] Error for input '.parameter': Invalid directive'
21:12:32.077: [Debug] - SmaliTool.Smali: 'Smali: D:\ADMIN\TEMP\user\DF5FD0\smali\com\sony\smallapp\internal\util\DialogHelper.smali[19,15] mismatched input '"w"' expecting END_METHOD_DIRECTIVE'
21:12:32.077: [Debug] - SmaliTool.Smali: 'Smali: D:\ADMIN\TEMP\user\DF5FD0\smali\com\sony\smallapp\internal\util\WindowUtils.smali[83,4] Error for input '.parameter': Invalid directive'
21:12:32.077: [Debug] - SmaliTool.Smali: 'Smali: D:\ADMIN\TEMP\user\DF5FD0\smali\com\sony\smallapp\internal\util\WindowUtils.smali[84,4] Error for input '.parameter': Invalid directive'
21:12:32.077: [Debug] - SmaliTool.Smali: 'Smali: D:\ADMIN\TEMP\user\DF5FD0\smali\com\sony\smallapp\internal\util\WindowUtils.smali[83,15] mismatched input '"context"' expecting END_METHOD_DIRECTIVE'

21:12:32.078: [Normal] - SmaliTool.Smali: 'Smali failed, see log for further information.'
21:12:32.078: [Debug] - SmaliTool.Smali: 'Exitcode: 1'
21:12:32.081: [Error] - SmaliModule.ExecuteInternal: 'framework2 -> Assemble smali files : Assembling smali failed!'
21:12:32.081: [Error] - Script.ExecuteScript: 'Executing framework2 -> Assemble smali files failed!'
21:12:32.081: [Error] - Script.ExecuteScript: 'Failed module is essential, aborting script execution!'
'Nazwa nie może rozpoczynać się od znaku '"' ani wartości szesnastkowej 0x22. wiersz 677, pozycja 74' mean 'Name cant start from "" or hex value 0x22, verse 677, position 74'
I dont understand it as i didnt change anything, only copied files from resources
 

Kevin-0100

Senior Member
Feb 16, 2013
124
70
Vlaardingen
Xperia XZ2
OnePlus 7T
I haven't tested the newest virtuous ten studio update much but going of your log I think it is using apktool 2.0, which is producing the smali error parameter invalid directive.

Look in settings and see if you can set it to use apktool 1.5.2 and see if it resolves the issue.

As for the hex value at line 677, I'm not sure, I would have to check if the value is correct.

Sent from my C1905 using XDA Premium 4 mobile app
 
Last edited:

allanlhdz

Senior Member
Oct 7, 2013
63
24
Cartago, Paraiso
My computer don't work!
Please Someone port modifier files or create a thread with modifier files for legacy xperia 319 :)
Thanks in advance!

Sent from my ST18i using CyanogenMod 11 (319) XDA Free APP
 
I think VTS is not for me. I cant see anything in it, ie how to change apktool version. Many things looks different than on ur scrennshots - ie when creating new solutioin/project I dont have so many tabs on "create new project" window - its coz of changes in newer version or I just dont turn on advanced settings?
1zb53eb.png
 

black.ic3

Senior Member
Jun 1, 2013
742
2,371
L'viv
Dont working

I cant make the SystemUI work
It is disappearing

But there is another problem
I downloaded Small Apps Laucher from market to test small apps
I can see my small apps in the list, but if press button with small app it doesnt work, it must shown up, but no reaction...

Maybe you can share your files that work?
 
  • Like
Reactions: grigorian941
So I used 1.5.2 for framework2.jar and it worked. Really thanks!
But now I cant go throught editing SystemUI. Apktool 2.0.0 is decompiling it but i dont get smali folder. 1.5.2 gives a lot of errors, in the end I have smali, but coz errors are about something important I cant recompile it (even if I could I would probably got systemui fc's)

17:07:06.932: [Error] - ApkTool.DecompileApk: 'ApkTool: I: Copying raw classes.dex file...'
17:07:06.932: [Error] - ApkTool.DecompileApk: 'ApkTool: I: Loading resource table...'
17:07:06.932: [Error] - ApkTool.DecompileApk: 'ApkTool: I: Loaded.'
17:07:06.932: [Error] - ApkTool.DecompileApk: 'ApkTool: I: Decoding AndroidManifest.xml with resources...'
17:07:06.932: [Error] - ApkTool.DecompileApk: 'ApkTool: I: Loading resource table from file: D:\ADMIN\apktool\framework\1-1.apk'
17:07:06.932: [Error] - ApkTool.DecompileApk: 'ApkTool: W: Config flags size > 36. Exceeding bytes: 0xFFFF.'
17:07:06.932: [Error] - ApkTool.DecompileApk: 'ApkTool: W: Invalid config flags detected: style-v17-ERR0'
17:07:06.932: [Error] - ApkTool.DecompileApk: 'ApkTool: W: Could not decode attr value, using undecoded value instead: ns=android, name=sharedUserId, value=0x00000024'
17:07:06.932: [Error] - ApkTool.DecompileApk: 'ApkTool: Exception in thread "main" java.lang.NullPointerException'
17:07:06.932: [Error] - ApkTool.DecompileApk: 'ApkTool: at java.io.Writer.write(Unknown Source)'
17:07:06.932: [Error] - ApkTool.DecompileApk: 'ApkTool: at brut.androlib.res.util.ExtMXSerializer.writeAttributeValue(ExtMXSerializer.java:38)'
17:07:06.932: [Error] - ApkTool.DecompileApk: 'ApkTool: at org.xmlpull.mxp1_serializer.MXSerializer.attribute(MXSerializer.java:673)'
17:07:06.932: [Error] - ApkTool.DecompileApk: 'ApkTool: at org.xmlpull.v1.wrapper.classic.XmlSerializerDelegate.attribute(XmlSerializerDelegate.java:106)'
17:07:06.932: [Error] - ApkTool.DecompileApk: 'ApkTool: at org.xmlpull.v1.wrapper.classic.StaticXmlSerializerWrapper.writeStartTag(StaticXmlSerializerWrapper.java:267)'
17:07:06.932: [Error] - ApkTool.DecompileApk: 'ApkTool: at org.xmlpull.v1.wrapper.classic.StaticXmlSerializerWrapper.event(StaticXmlSerializerWrapper.java:211)'
17:07:06.932: [Error] - ApkTool.DecompileApk: 'ApkTool: at brut.androlib.res.decoder.XmlPullStreamDecoder$1.event(XmlPullStreamDecoder.java:80)'
17:07:06.932: [Error] - ApkTool.DecompileApk: 'ApkTool: at brut.androlib.res.decoder.XmlPullStreamDecoder.decode(XmlPullStreamDecoder.java:130)'
17:07:06.932: [Error] - ApkTool.DecompileApk: 'ApkTool: at brut.androlib.res.decoder.XmlPullStreamDecoder.decodeManifest(XmlPullStreamDecoder.java:144)'
17:07:06.932: [Error] - ApkTool.DecompileApk: 'ApkTool: at brut.androlib.res.decoder.ResFileDecoder.decodeManifest(ResFileDecoder.java:131)'
17:07:06.932: [Error] - ApkTool.DecompileApk: 'ApkTool: at brut.androlib.res.AndrolibResources.decode(AndrolibResources.java:218)'
17:07:06.932: [Error] - ApkTool.DecompileApk: 'ApkTool: at brut.androlib.Androlib.decodeResourcesFull(Androlib.java:115)'
17:07:06.932: [Error] - ApkTool.DecompileApk: 'ApkTool: at brut.androlib.ApkDecoder.decode(ApkDecoder.java:114)'
17:07:06.932: [Error] - ApkTool.DecompileApk: 'ApkTool: at brut.apktool.Main.cmdDecode(Main.java:146)'
17:07:06.932: [Error] - ApkTool.DecompileApk: 'ApkTool: at brut.apktool.Main.main(Main.java:77)'
 

Top Liked Posts

  • There are no posts matching your filters.
  • 25
    First of all: this guide is based off the guide by @lukakas found here http://xdaforums.com/showthread.php?t=2460877

    I tweaked it to get it to work on CM11, comparing the files of the Z2 system dump, the 4.3 resources provided in the guide by @lukakas and compared the difference with CM11 files.

    In this guide I am using OPENsemc rom beta 3, wich is CyanogenMod 11 / Android KitKat

    Before flashing the files, perform a FULL BACKUP in case something goes wrong!

    Code:
    I will NOT be held responsible if something happens to your device while or after flashing any of these files! All flashing is done at your OWN RISK.



    I recommend using Virtuous Ten Studio for editing the files. It can be downloaded from: http://www.virtuous-ten-studio.com/index.php/downloads

    Setting up Virtuous Ten Studio

    Click on “File” then on “Open Settings” then proceed to ApkTool, and install Framework-res.apk from the rom you are trying to port SmallApps to by clicking on “Add single framework”

    6rby.jpg



    Android.policy.jar

    Click on “Open” then on “New Project” and import anroid.policy.jar as shown below:
    (note, in properties/settings click on “Smali” and make sure the API is set to 4.4 KitKat)

    v4bz.jpg


    Now open smali\com\android\internal\policy\impl\PhoneWindowManager.smali and select checkAddPermission from the dropdown menu

    ob8x.jpg


    Find and alter the following lines of code: (added code is marked in green)

    .method public checkAddPermission(Landroid/view/WindowManager$LayoutParams;[I)I

    (Lines of code not needed in the part of the tutorial has been cut, do not delete them though)
    :cond_1
    const/4 v0, 0x0

    .line 1609
    .local v0, permission:Ljava/lang/String;
    sparse-switch v1, :sswitch_data_0

    (Lines of code not needed in the part of the tutorial has been cut, do not delete them though)

    :sswitch_1
    const-string v0, "android.permission.SYSTEM_ALERT_WINDOW"

    .line 1627
    const/16 v3, 0x18

    aput v3, p2, v2

    goto :goto_1

    .line 1397 - This number should be a new number and should not be found elsewhere in this document
    :sswitch_2
    const-string v0, "com.sony.smallapp.permission.SMALLAPP"


    .line 1398 - This number should be a new number and should not be found elsewhere in this document
    goto :goto_1


    .line 1609 - This number must match the number above the line.local v0, permission:Ljava/lang/String;
    nop

    :sswitch_data_0
    .sparse-switch
    0x7d2 -> :sswitch_1
    0x7d3 -> :sswitch_1
    0x7d5 -> :sswitch_0
    0x7d6 -> :sswitch_1
    0x7d7 -> :sswitch_1
    0x7da -> :sswitch_1
    0x7db -> :sswitch_0
    0x7dd -> :sswitch_0
    0x7e7 -> :sswitch_0
    0xbb5 -> :sswitch_2
    0xbb6 -> :sswitch_2

    .end sparse-switch
    .end method

    Press control s to save the document and recompile it: (use right click on android.policy and click “Build project”


    Framework2.jar

    For this step, import and decompile Framework2.jar like in steps show above. Right click on “framework2” and select “Open in windows explorer”

    In the explorer screen, navigate to Data/smali/com, copy and paste the “sony” folder provided in the resources zip. Once done, right click on “framework2” and select “Reload project”

    Once the project has reloaded, right click on “framework2” and select “Build project”

    Framework-res.apk

    Import framework-res.apk into the project.
    Note: make sure before importing that in the Apk-Tool section you select “Use newest ApkTool” and that you select the Framework tag. (Remember you installed framework-res.apk earlier?)

    Once framework-res.apk has imported, open AndroidManifest.XML
    Add the lines marked in green like below.

    <permission android:name="com.sony.smallapp.permission.CONTROL_SMALLAPP" android:protectionLevel="system|signature" />
    <permission android:label="@string/permlab_smallapp" android:name="com.sony.smallapp.permission.SMALLAPP" android:protectionLevel="dangerous" android:description="@string/permdesc_smallapp" />
    <permission android:label="@string/permlab_taskSwitcherPluginView" android:name="com.sonymobile.permission.TASK_SWITCHER_PLUGIN_VIEW" android:protectionLevel="signatureOrSystem" android:description="@string/permdesc_taskSwitcherPluginView" />
    <permission android:name="com.sonymobile.permission.ACCESS_BEACON_MANAGER" android:protectionLevel="system|signature" />


    drm8.jpg


    Don’t forget to save the modifications you just made.

    Next up: open res/values/ and open “strings.xml”

    At the end of the file, copy the green lines:

    <string name="permlab_smallapp">Small application overlay</string>
    <string name="permdesc_smallapp">Allows running movable small applications on top of other applications.</string>
    <string name="permlab_taskSwitcherPluginView">Provide plugin-view to the task-switcher</string>
    <string name="permdesc_taskSwitcherPluginView">Allows the application to provide a plugin-view to the task-switcher</string>


    r0tn.jpg


    Save your modifications and and “Build project”

    SystemUI.apk

    This part can be the trickiest and can cause a lot of headache. Import SystemUI.apk and open AndroidManifest.xml

    Note: make sure before importing that in the Apk-Tool section you select “Use newest ApkTool” and that you select the Framework tag.

    Add the lines marked in green like below.

    <uses-permission android:name="com.sonymobile.permission.XSSM_PROVIDER" />
    <uses-permission android:name="com.sonymobile.permission.XSSM" />
    <uses-permission android:name="android.permission.BIND_APPWIDGET" />
    <uses-permission android:name="com.sony.smallapp.app.widget.permission.BIND_SMALLAPP_WIDGET_MANAGER" />
    <uses-permission android:name="com.sony.smallapp.permission.SMALLAPPMANAGER_CONTROL" />
    <uses-permission android:name="com.sony.smallapp.launcher.permission.ACCESS_DATABASE" />
    <uses-permission android:name="android.permission.DELETE_PACKAGES" />
    <permission android:name="com.sonymobile.permission.TASK_SWITCHER_PLUGIN_VIEW" android:protectionLevel="normal" />


    x2vu.jpg


    Add the lines marked in green like below. (in Recents Activity)

    <action android:name="com.android.systemui.recent.action.OPEN_RECENTS_INTENT_FROM_SMALL_APP_LAUNCHER" />


    tll4.jpg


    Now navigate to res/values/ and open “attrs.xml”

    Add the line marked in green at the end of the file:

    <attr name="lookupKey" format="string" />



    5w0x.jpg



    Now navigate to res/values/ and open “ids.xml”

    Add the line marked in green at the end of the file:

    <item type="id" name="recent_wipe_app">false</item>
    <item type="id" name="recents_inject_custom_view">false</item>
    <item type="id" name="recents_layout">false</item>
    <item type="id" name="recents_pluginview_container">false</item>


    xf8z.jpg


    Now navigate to res/values/ and open “public.xml”

    Since we will be working with hex id’s, a word of advice.

    Always create a new hex id in this file. Duplicating other hex number will result in a fail when trying to recompile


    As an example:

    <public type="attr" name="maxSize" id="0x7f010008" />
    <public type="attr" name="holdTime" id="0x7f010009" />
    <public type="attr" name="decayTime" id="0x7f01000a" />
    <public type="attr" name="orientation" id="0x7f01000b" />
    <public type="attr" name="singleRow" id="0x7f01000c" />
    <public type="attr" name="lookupKey" id="0x7f01000d" />

    Notice that all the hex number are sequential? All these numbers are only found once in the entire document. If I were to add another line below LookupKey it would look like this:


    <public type="attr" name="Tutorial" id="0x7f01000e" />

    When in doubt as to if the number you assigned to a line, just copy the hex number and use control f to search for it. When you can’t find another line with that number, you know that your hex number is one of a kind.

    Let’s get started shall we.

    First of all locate the last “attr” line and add the line below marked in green:

    <public type="attr" name="lookupKey" id="PUT_HEX_HERE" />


    6ipu.jpg


    Locate the last “layout” line (like where you put LookupKey in the example above) and add line below marked in green:

    <public type="layout" name="plugin_view" id="PUT_HEX_HERE" />

    Locate the last “id” line and do the same with the line below

    <public type="id" name="recents_inject_custom_view" id=" PUT_HEX_HERE" " />
    <public type="id" name="recents_layout" id=" PUT_HEX_HERE" " />
    <public type="id" name="recents_pluginview_container" id=" PUT_HEX_HERE" " />


    Now copy and paste (and overwrite) the files in the resources to res/layout and res/layout-land.

    Now copy and paste (and overwrite) the .smali files in the resources to com/android/systemui and com/android/systemui/recent

    Before going any further, don’t forget to save ALL the modifications you made and after that you need to right click on “SystemUI” and click on “Reload project”

    Now open up RecentsActivity.smali

    Virtuous Ten Studio helps you in which lines you need to alter. Every line that has an hex id will be marked by a little blue box

    kry8.jpg


    In the example above, 0x7f07007f represents “recents_pluginview_container” you need to change that hex number to the number you assigned to it earlier in “public.xml”

    You need to change every hex number in this file to match the hex numbers you assigned earlier.

    These are:

    recents_pluginview_container
    recents_layout
    plugin_view
    status_bar_recent_panel
    recents_root
    config_recent_item_min_alpha
    recents_pluginview_container
    recents_return_to_launcher_enter
    recents_return_to_launcher_exit

    Note that the list above is in the same order as the lines containing the hex numbers in RecentsActivity.smali. This means that “recents_pluginview_container” represents the first hex number, “recents_layout” the second, “plugin_view” the third etc. etc.

    Once that is done, save the file and open R$styleable.smali.

    Find line: sput-object v0, Lcom/android/systemui/R$styleable;->RecentsPanelView:[I

    plid.jpg


    Change that hex id to match the id for LookupKey, you added that in “public.xml”.

    Save all modifications and build your project.

    Zip up all the files in a flashable zip and start flashing

    These are all the steps I made to get it working, I hope this guide will help others to port SmallApps/Taskswitcher.
    3
    Later this evening I will upload my modded files for you to try :)

    Sent from my C1905 using XDA Premium 4 mobile app
    2
    Error on

    \res\layout\status_bar_recent_panel.xml:11: error: Error: No resource found that matches the given name (at 'id' with value '@id/recents_clear').'
    \res\layout-land\status_bar_recent_panel.xml:11: error: Error: No resource found that matches the given name (at 'id' with value '@id/recents_clear').'

    what should I do

    Using Beanstalk ROM
    I found similar error and fix by find some similar picture
    I already change @drawable/ic_recents_clear to @drawable/ic_notify_clear_normal in both status_bar_recent_panel.xml

    You need to go to res/values/ids and make a new value for recents_clear. That should fix it

    Sent from my C1905 using XDA Premium 4 mobile app
    2
    If you get a logcat you could try finding the reason for the FC

    Sent from my C1905 using XDA Premium 4 mobile app
    2
    i am success.1399219373851.jpg1399219386313.jpg1399219398581.jpg



    look nice .thank you very much.mate
    Sent from my LT26i using XDA Free mobile app