yashsingh1/xdaforums huggingface dataset:
[Nexus 7 Android Development] barrmulio:
hey everyone - sorry i've been on a hiatus due to personal issues and a side job that's finishing up

if you want this, then there's are plenty of roms that offer it - sgt7, cm10, eos, pa, and some others - it's not easy to build and still requires systemUI changes to happen though so it won't be in scope for this patch

not on stock launcher that i know of...use nova or apex and they can keep the bottom dock and select number of rows

you understand it pretty well - if you want to 'outsmart' apps - then you need paranoid android, since moles has done a *ton* of work to manually work around layout and resolution issues...some apps don't even trigger tablet mode at the same dpi as others (e.g. google play won't trigger until 160 or so, same for garmin, but most of the OS does at 177)...moving the notifications will be out of scope for this patch...i suggest you consider paranoid android since it has a 'smaller' tab mode that does a great job shrinking the notification/status bar slightly to fit more visually

yep - that was reported in a slightly different way - mainly due to the editing of the stock launcher to get more usable space

not my focus right now because nova/apex provide much better functionality than stock without the need to hack the layouts and are already on the jb codebase - but definitely something i need to correct
[Nexus 7 Android Development] Fusion777:
Look forward to having you back. I love this patch and eager for any updates you do. Thanks again for it!
[Nexus 7 Android Development] edgex:
I don't think this made me lose root, but SU auto denies everything, even SU from updating. I set it to auto allow in SU settings and everything. IDK whats going on but I basically don't have root. I tried reflashing root via the toolkit, no help either.
[Nexus 7 Android Development] barrmulio:
there's no reason it would make you lose root, did you try to flash supersu by chance?
[Nexus 7 Android Development] zlwu:
Looking forward to the Hybrid UI mode .
[Nexus 7 Android Development] fleshdeep:
Did you know he wasn't calling Jelly Bean Project Butter?
[Nexus 7 Android Development] oliverano:
Could I just flash a stock deodexd rom and then aply this pach, instead of deodexing the stock rom that comes with the Nexus 7?
[Nexus 7 Android Development] Attictron:
Yup.
[Nexus 7 Android Development] Scott:
New version of DropBox doesnt F/C upon launching any more :good:
[Nexus 7 Android Development] Jdbye:
System UI FC's on MCR jr7 using motley kernel 1.1.1. Saw someone had successfully used the patch on MCR jr5 but it seems to no longer work on jr7.
[Nexus 7 Android Development] fleshdeep:
Does this work on Bugless Beast?
[Nexus 7 Android Development] neurod:
**Off topic a bit

What clock widget is being used in the op?
[Nexus 7 Android Development] ziggy34:
Quick search of this thread.......

http://xdaforums.com/showthread.php?p=29401655&highlight=clock#post29401655

Sent from my A500
[Nexus 7 Android Development] unomedmen1:
I flashed over Pete's latest off a fresh/clean install and got error message (something about android.process) as soon as got to lock screen.
[Nexus 7 Android Development] Jameswgm:
When I flash this over Jr7, I lose my EPM options: is this a known issue? Is there a way to prevent this happening?

On JRO03D Jr7 w/ stock kernel.

James.
[Nexus 7 Android Development] kaizvn:
I backup all my apps via titanium backup, after that I flash DEODEXED of barrmulo, next is truetabletUI. If it occur error, try to do factory reset your device, all maybe no UI error, final restore apps. With me it's work fine.

p.s : remember wipe cache and davik cache before flash TabletUI
[Nexus 7 Android Development] Jameswgm:
I tried factory restore and reinstall now all typically all I'm getting is system ui errors! I have it working perfectly aside from the additional power options included in Jr7; restart and recovery are removed from the power menu when Tablet UI is flashed.

Is there anyone who flashed from Jr7 who can confirm that either they still have these options, and that I've made an error; or whether the Tablet UI.zip overwrites these power options. Would be much appreciated.
[Nexus 7 Android Development] SiNJiN76:
I'm not using jr7 but my power options got over written.. And now I can't use my tablet until I get home. Phone. Com keeps FCing... And there is no way for me to get into recovery to re flash since getting into recovery from bootloader is borked. :mad:. :silly:
[Nexus 7 Android Development] spiff72:
Can you get to a terminal emulator window and type REBOOT? Or use an app like Quick Boot to get to recovery mode?
[Nexus 7 Android Development] SiNJiN76:
Nah... It's an instant fc... Can't do anything in between.
[Nexus 7 Android Development] quaff:
trying to download alpha 1, but the mirror is down, can someone upload alpha 1 for me?

thanks!
[Nexus 7 Android Development] jamesst20:
No need to have custom launchers to have rotation, you can force it without changing the ui.

1st. Create a file (Need root) : /data/local.prop

2nd Type in it : launcher.force_enable_rotation=true

3rd : Save

4th Reboot

There you have your rotation :)

and also, by adding this following line,

qemu.sf.lcd_density=160

will force ui density to 160. I think it is the same as this patch.
[Nexus 7 Android Development] inteks:
after this patch the voicesearch dosnt work anymore :(

i checked this twice (restored org file / install patch)

i found this in logcat

E/AndroidRuntime( 2028): java.lang.RuntimeException: java.util.concurrent.ExecutionException: java.lang.UnsatisfiedLinkError: Native method not found: com.google.speech.recognizer.AbstractRecognizer.nativeCancel:(J)I
[Nexus 7 Android Development] taitony:
If your ROM is Paul's JRx, please do not flash this patch. It will damage SystemUI and cause many apps to FC.

I use my NAND backup to restore the system and boot to recover the problem.

---------- Post added at 06:43 PM ---------- Previous post was at 06:40 PM ----------

I am JR7 too. You are lucky and I have to restore system and boot from NAND backup.

I show SystemUI FC.

.
[Nexus 7 Android Development] eturk01:
Anyone having luck with a version for nexus 7 with CM10?

Trying alpha 1, as suggested, couldn't even boot.
[Nexus 7 Android Development] oliverano:
It's only for stock roms for now.
[Nexus 7 Android Development] the.emilio:
Works great on CleanROM. No issues with flashing and booted up perfect. Great job!
[Nexus 7 Android Development] oliverano:
Does the first boot take very long? im sitting here and waitng 10m in now

thx
[Nexus 7 Android Development] cassius_20:
Not for me. Nandroid backed up, followed all pre-reqs before flashing, flash/wipe dalvik/reboot recovery/wipe dalvik once more/fix permissions, then rebooted.

No problems so far, great job, can't wait for next update!

Nexus 7/R3 biaaatch
[Nexus 7 Android Development] hoosbude:
I got bored waiting for an update so moved to paranoid android rom, it is so much better and scaling can be set on a per app basis.
[Nexus 7 Android Development] the.emilio:
You are deodexed right? I booted up within a minute on CleanROM. As the OP says you must be deodexed or use his deodex script.
[Nexus 7 Android Development] Nark.GA60:
Hi,

I built CM10 last night with the changes to PhoneWindowManager and WindowsManagerService. It works brilliantly but I'm wondering if you could describe the changes to the launcher and framework-res to fix the spacing and the lock screen rotation?

I tried to search through the thread but couldn't find any mention of what the changes were.
[Nexus 7 Android Development] osm0sis:
This is exciting! I personally can't wait for hybrid mode. :D
[Nexus 7 Android Development] LouisTran:
I flashed this patch on Codenameandroid rom but i've freeze in nexus 7 logo, is any1 know any solution?
[Nexus 7 Android Development] arhung:
may I ask for the name of widget of the op screenshot??thx
[Nexus 7 Android Development] barrmulio:
folks - just providing an update an bad news -

i've been pretty omnipresent for a while now due to personal issues which still persist - I need to focus on family and work which is cutting significantly into any remaining dev time that I would have...so the discussions around hybrid mode, settings toggle, are probably not going to happen any time soon

i do continue to get back to pms quickly

for those of you kind enough to donate - thank you and i will be returning those donations given the halted dev

if anyone is interested in picking this project up, let me know via pm

as for custom roms - as i've said many times and in the op above the downloads - this was designed for JRO03D - once a dev starts adding stuff to their rom, this will cause fc's, loose parts of the rom (like EPM/APM), etc - please ask that dev to use the guide in the first post of the op or pm me if they have questions

some answers to recent posts

one more clock from google play

This wont work with CM10 - you can decompile android.policy.jar and services.jar and edit the smali files to make the same mods...if you compile your own CM10, then just follow the directions on the first post. Releasing a patch for CM10 will be a bit tough gives that services.jar will likely change and morph until it's a bit more stable....

You may want to share the CM10 patch :) Just inject them into one of the zips and I can post to the OP if you want

I'm surprised the launcher needed patching - Trebuchet didn't need patching in the past with this mod but here are the commits:

https://github.com/barrmy/packages_apps_Launcher2/commit/ac5c0e722ea42e0edec7d64b65fb8d711eff0edd

https://github.com/barrmy/packages_apps_Launcher2/commit/92268f9c0b03ac0ce4f481af5843e0ad8a8524a2

as for the lockscreen rotation -

https://github.com/barrmy/frameworks_base/commit/9c3b0920488736e821e27e0e9eb2a8582ce9c456

my github is a complete mess, so just reference these rather than cherry picking or merging

if you flash codenameandroid again it should overwrite the files, either that or adb push the files from codenameandroid that were replaced with the patch zip you used...
[Nexus 7 Android Development] osm0sis:
Truly sorry to hear that barrmulio, but all the best in your personal life; it definitely comes first.

Do you have a recommendation on who else has been doing good work on the tablet ui/hybruid for the N7?
[Nexus 7 Android Development] Rsotbiemrptson:
Zips for stock 4.1.1

Hello,

I would like to say thanks for your work, it has brought my N7 much needed changes. I had to modify the files as I am still running stock 4.1.1(JRO03D odexed). I have it working for non deodexed roms incase anyone that hasn't flashed a custom rom wants to try it. I have also uploaded a zip to revert back to stock just incase. Both can be flashed through recovery, wipe cach and dalvik after flashing.

TabletUI

https://www.dropbox.com/s/e63uj4l2tynfrfc/TabletUI.zip?m

StockUI

https://www.dropbox.com/s/27btzfayophnd9h/StockUI.zip?m

Rsotbiemrptson
[Nexus 7 Android Development] z1gackly:
This may be a bit of a long shot, but maybe someone can help. I built the code changes suggested in the OP into my personal CM10 ROM today, and it worked flawlessly, except for one thing.

I use Nova Launcher, and I like the way the dock moves to the side when you flip into landscape mode. I know this was preserved in earlier Tablet UI modes of sgt7 and in Glazed 1.1.2, but in my ROM, Nova drops the dock to the bottom of the screen in landscape.

I've gone through all the Nova settings and can't find what could be causing this, and it's doing my head in.

Does anyone have any suggestions?

barmulio, what would you need to make a CM10 patch for others to use? Just android.policy.jar and services.jar?

Hope things go well for you in your personal and work life, and thanks for the work.
[Nexus 7 Android Development] barrmulio:
thank you everyone for your support

ParanoidAndroid is by far the most advanced work, and now that it's open source I would hope some pieces would be integrated with other roms - PA has really been the only one to crack the code there to allow for apps to be configured for tablet mode independently of the actual system UI and moles put in a ton of work to make that happen ... AFAIK

SGT7 and a few others have tablet system UI, but not tablet apps

so it will depend a bit on what you're after - if you just care for the UI in the system (ie the bottom, unified navbar/statusbar), there are lots of great options...if you want the apps to behave in tablet mode, PA is by far the best, but it's a full rom experience too (for many technical reasons, some of which you can gleam for the history of this thread in having specific apps control their own tablet ui dpi behavior)

-------------

if i have to build one, i'll do it from scratch quickly...just need to apply the same settings to PhoneWindowManager and WindowsManagerService, compile a base rom, and then pull out the jars into a flash zip....in the past CM-based roms didn't have an issue with their launcher (trebuchet) like aosp/stock builds did
[Nexus 7 Android Development] z1gackly:
Hold fire on that build, I have a zip with the jars in it for you here: http://db.tt/sJgCkUym

Just not sure how to make it flashable.
[Nexus 7 Android Development] Nark.GA60:
Thanks for that. I'll give them a go and hopefully provide a patch tonight (I've only just woken up).
[Nexus 7 Android Development] barrmulio:
gotcha - i had misunderstood

i added those two files it to a flashable zip here - https://www.dropbox.com/s/q83fxfdxpa1q2s2/CM10tabletUI-test1.zip

need some folks to test please - please note this zip does not backup prior files so ensure you have a CM10 zip to flash if something goes wrong

to mod a zip, just take an existing one, open the zip in winzip/winrar/archive manager and drag/drop the files into the /framework or /system folders in the zip...then pull out /META-INF/com/google/android/updater-script and edit that to say whatever message or credits you want while it's flashing, or tweak in case you added new/different files
[Nexus 7 Android Development] aaronpoweruser:
Maybe someone will, check back in 48 hours or so ;)
[Nexus 7 Android Development] osm0sis:
I'll check out Rsotbiemrptson's stock pre-patched version of True Tab and see how it feels and then explorer and figure out if I want to go all out with PA. Limited to 8 thanks/day but thank you very much for the response and all your hard work on the patch.:good:
[Nexus 7 Android Development] z1gackly:
Thanks for the info. I'm pretty new to Android development.

I tested the zip you made on an earlier build of mine and it caused a SystemUI FC loop the first time I booted. The second time I booted, it force closed SystemUI just once and then functioned perfectly. I am just about to boot a third time, and then I will try it on an official CM nightly build, but it seems a little temperamental! I didn't get that effect with the build that I took the jars from.

EDIT: Just realised I may know what's causing the FCs. Await further testing shortly ;)
[Nexus 7 Android Development] barrmulio:
did u clear dalvik before flashing?

i just started a full cm10 build...will be a few hrs before it gets done, patched, rebuilt
[Nexus 7 Android Development] z1gackly:
Works fine with today's official CM10 nightly. I think it was clashing with a framework base cherry pick in the first build I tested it on.
[Nexus 7 Android Development] Nark.GA60:
This is my CM10 build from last night. All I've done is changed the two files mentioned in the OP and replaced Trebuchet with the patched Launcher2. Lockscreen doesn't rotate, but you can just disable lockscreen in the settings to avoid that.

https://www.dropbox.com/sh/i9t50y61vqdu6xp/PlYXuUMPed/CM10+TabletUI

I'll try fixing the launcher and lockscreen tonight (in about 12h time) and provide a patch. Unless someone else beats me to it.
[Nexus 7 Android Development] z1gackly:
You've got me properly confused here, because in CM10 Trebuchet will rotate if you check the "Auto-rotate screen" box in Settings->Launcher->General and the Lockscreen will rotate if you enable it in Settings->Display->Rotation, so I'm not sure what you're trying to fix!

For me, everything works fine with CM10 if you just make the two code changes in the OP. I wouldn't advise cherry picking the centre clock mod with it though, as that causes SystemUI problems.
[Nexus 7 Android Development] Nark.GA60:
Hey, hadn't noticed that lock screen rotation setting! It worked. Thanks for pointing that out.

The problem with Trebuchet was that the icon spacing was all out of whack. The bottom row of icons was chopped in half.
[Nexus 7 Android Development] z1gackly:
Ah ok, let me try your Launcher2 then to see what the difference is, and I'll report back. Must admit, I never use Trebuchet anyway, I prefer Nova.

EDIT: see what you mean now.
[Nexus 7 Android Development] LouisTran:
I just wanna ask how can i flash your patch in codenameandroid @@ i tried few time but nothing changed
[Nexus 7 Android Development] Nark.GA60:
I prefer Nova on the phone but I've found the interface to be not as good on the tablet. There are a few little things that annoy me. Hopefully they'll fix it up soon.

He was explaining to you how to get back to a working system. The patch is not compatible with codenameandroid.
[Nexus 7 Android Development] barrmulio:
grab the new beta..they fixed a lot of quirks, i'm back to using it over apex now
[Nexus 7 Android Development] barrmulio:
need a logcat to help...see my signature for how
[Nexus 7 Android Development] LouisTran:
Thanks so much, but I did not pass to the boot, it freezed at there so i have reflash the rom, does the logcat still available (i wiped all)? If yes i will try to get it then send to you :)
[Nexus 7 Android Development] z1gackly:
Ok, here is a flashable Tablet UI patch for CM10, tested successfully on the latest nightly, including Nark.GA60's modified launcher and credits in the updater script for all involved.

This works perfectly for me, but it would be great if someone else could test it too!

http://db.tt/ke1RrQ6u
[Nexus 7 Android Development] Nark.GA60:
Just tested and working like a charm.

I can't take credit for the Launcher2 though. It was just taken from barrmulio's ROM in the OP.

Looks like I won't get a chance to do the fixes to Trebuchet tonight. I'll try to find some time over the weekend. What you've done with that patch is good enough IMO. Great work!
[Nexus 7 Android Development] z1gackly:
I took the framework_res.apk from your ROM so you get credit anyway ;)

Thanks for testing it. Looking forward to seeing what you come up with for Trebuchet.
[Nexus 7 Android Development] barrmulio:
no, you need to grab it while you are stuck booting - it will tell us what app is causing the freeze
[Nexus 7 Android Development] barrmulio:
thanks z1gackly and Nark.GA60! added this to the op

thanks Rsotbiemrptson! added your links to op as well
[Nexus 7 Android Development] kaizvn:
http://xdaforums.com/showthread.php?t=1830016

scrosler said that his cleanROM include your patch.

is it your last patch barrmulio ?
[Nexus 7 Android Development] Noobla_Khan:
+1
[Nexus 7 Android Development] barrmulio:
it should be - we've been pm'ing on integration
[Nexus 7 Android Development] toker_X1:
Installed on fresh cm10

'extend desktop' menu is missing from power button

Is there way to add it manually?
[Nexus 7 Android Development] z1gackly:
I'm going to have a good look at the settings menus after the weekend. I'd like to be able to enable some of the notification drawer settings for the tablet UI as well. I'm pretty new to Android development though, so I need to get my head around it.
[Nexus 7 Android Development] toker_X1:
Thanks for looking.

It's a nice option for apps / games that run full screen.
[Nexus 7 Android Development] mazlano27:
Hi, the laucher doesnt launch after applying this patch to a stock rom. any ideas why? hmmm
[Nexus 7 Android Development] Nark.GA60:
Got a logcat? You didn't apply the CM10-specific version of the patch, did you?
[Nexus 7 Android Development] mazlano27:
No logcat, and i applied alpha 3

Rom:e.g. Stock version JRO03D

Kernel: stock

Issue Description: After applying the patch, as soon as the tablet turns on, launcher does not run, it crashes.
[Nexus 7 Android Development] PhilDX:
are you deodexed? Read the prerequisites in the second post...
[Nexus 7 Android Development] osm0sis:
Thanks again for this, but I'm the type to always look through a CWM zip before flashing it and I had a question. I notice your Stock restore zip has an odex file for Launcher2 whereas your Tablet patch zip does not. Is this intended? Cheers.

Edit: NM, I see you used the updater-script to remove the .odex in the patch zip so that you can use the patched deodexed Launcher2. :good:

Edit 2: Okay. New question. Any way to patch only the lock screen for rotation? I haven't seen one yet. :)

Edit 3: NM again. Hunted it down: framework-res.apk/res/values/bools.xml, line 35, "config_enableLockScreenRotation"
[Nexus 7 Android Development] jamesst20:
Dude! It is really awesome!! Thanks man! Can we fix the toggle widget size? Cant center it :/

Can we also fix the issue with apps name ? Some apps name are too long and touch other apps label :(

Stock 4.1.1 - Nexus 7
[Nexus 7 Android Development] osm0sis:
De/Recompiled framework-res.apk using apk multi-tool, altering that line in bools.xml, but my lockscreen still doesn't rotate. This is likely because I'm running stock odexed though this doesn't make sense to me seeing as framework-res.apk doesn't have an odex file.
[Nexus 7 Android Development] jamesst20:
I'm using fully stock odexed and the lockscreen rotation works,

Envoyé depuis mon Nexus 7 avec Tapatalk
[Nexus 7 Android Development] osm0sis:
I'm trying to get ONLY the lockscreen rotation to work. :(
[Nexus 7 Android Development] kaizvn:
barrmulio, it's seem lockscreen auto rotate on CM10 didn't work, right?
[Nexus 7 Android Development] Nark.GA60:
It's in Settings > Display > Rotation
[Nexus 7 Android Development] imaleecher:
Thanks Rsotbiemrptson, patch works great! :good:
[Nexus 7 Android Development] kaizvn:
I mean Lock screen rotation.

the home screen rotate well, but Lock screen not work ( CM10)
[Nexus 7 Android Development] Nark.GA60:
In that menu, there's an option for lock screen rotation. Make sure it's ticked.

Works for me.
[Nexus 7 Android Development] kaizvn:
which ROM are you using, dude?
[Nexus 7 Android Development] Nark.GA60:
CM10.

Screenshot attached. It's the "Include lock screen" option.
[Nexus 7 Android Development] mateorod:
Hey guys,

Barrmullio already knows, but I put up a thread for the Auto-Patcher in the Nexus 7 Android dev. forum last night.

It has patches that automatically apply the edits from this post to any CM10, AOKP or AOSP rom. It will probably work for most of the roms in this forum, you will ust need to specify which base the rom is from if you use one of the custom roms.

I didn't include the Launcher2.apk because it is so large and because CM10 and AOKP have their own launchers anyway. If you use the AOSP-jb patches, you will need to flash the attached zip, which has been taken from barrmullio' package.

I left the script mostly the same, so your credits are still there, bar.

Let me know how it works if you try it, there are a bunch of Nexus 7 specific mods in there.
[Nexus 7 Android Development] osm0sis:
The mod I'd really like is the one that Paul from MoDaCo made to disable the Jelly Bean 'Disable apps on startup' which is what hides Wallet, Ears, Magazines, etc. if you're not in the US.

Edit: Update on recompiling framework-res.apk for lockscreen rotation - total success! I was losing my mind and felt like a total newb until I figured out there was a second bools.xml under /values-sw600dp/ that was superceding the one in /values/, so in summary (also adding forcing preferences to dual pane):

framework-res.apk

/res/values/bools.xml

<bool name="preferences_prefer_dual_pane">true</bool>

<bool name="config_enableLockScreenRotation">true</bool>

/res/values-sw600dp/bools.xml

<bool name="config_enableLockScreenRotation">true</bool>

:D