Android OS Forum banner
1 - 20 of 20 Posts

·
Marty Mcfly/Theme Dev
Joined
·
912 Posts
Discussion Starter · #1 ·
Working on my theme for the CM7 Theme Chooser, but am wondering how i throw layout edits from the framework into it. Would it be like below?

would just adding this to android.xml work,
<item name="layout/status_bar_latest_event_content">@layout/framework_status_bar_latest_event_content</item>
then copying the modified xml into the theme/res/layout folder and naming it to match?
 

·
THE MOST INTERESTING MAN IN ANDROID
Joined
·
223 Posts
Yes you are correct.. but you will also have to have in corresponding xmls or images that the modified XML calls for
 

·
Marty Mcfly/Theme Dev
Joined
·
912 Posts
Discussion Starter · #3 ·
Thanks man! Hitting you up on GTalk now.
 

·
Themer
Joined
·
575 Posts
I've been trying to push a few of these too. Keep getting errors when compiling that there is an error @id/something or string/something
I think that you also have to put the id.xml and the string.xml in the correct folders when compiling. I was going to try and figure this out tonight.
 

·
Marty Mcfly/Theme Dev
Joined
·
912 Posts
Discussion Starter · #5 ·
Good point about the styles.xml. or just add the entries you need to the existing one, like you would do for the colors.xml. don't know if you would need the ids.xml though. Need someone to weigh in on that.

Sent from 1885
 

·
Themer
Joined
·
575 Posts
When I build, if the layout.xml has a call to @id I get a compile error b/c the id doesn't exist. I might be doing something wrong though.
 

·
Marty Mcfly/Theme Dev
Joined
·
912 Posts
Discussion Starter · #7 ·
I guess make in id.xml to dump it all in, and just have any xml call out to the line in there?

Sent from 1885
 

·
Marty Mcfly/Theme Dev
Joined
·
912 Posts
Discussion Starter · #8 ·
Well this will save me quite a few hours... 1-4a Rename. Very basic, albeit, Very AWESOME renaming tool.
 

·
THE MOST INTERESTING MAN IN ANDROID
Joined
·
223 Posts
nmiltner said:
When I build, if the layout.xml has a call to @id I get a compile error b/c the id doesn't exist. I might be doing something wrong though.
just add an id.xml to the values folder.. you can just copy and paste the one from the apk you are trying to get the theme engine to create... or you can just create one and only add the id's you need that the xml... usually this is the easiest way IMO as then you don't have a bunch of unwanted id's in there that might cause confusion..
 

·
Marty Mcfly/Theme Dev
Joined
·
912 Posts
Discussion Starter · #10 ·
Exactly what I was planning on doing, just doing all the pngs right now.

Sent from 1885
 

·
THE MOST INTERESTING MAN IN ANDROID
Joined
·
223 Posts
Stetsonaw said:
Exactly what I was planning on doing, just doing all the pngs right now.

Sent from 1885
yeah i remember discussing this last night with you on gtalk :) ... you can do the same if you need an xml that is in a folder that is not in the theme engine template...
 

·
Marty Mcfly/Theme Dev
Joined
·
912 Posts
Discussion Starter · #12 ·
Yeah, like the drawable xmls i'll be adding for the animated status bar icons.
 

·
I am The reason you are theming
Joined
·
691 Posts
Pretty sure you cant make layout edits with the theme engine. It's based off activities. Which layouts.aren't. Hence whywr can't theme the lockscreen or volume rocker bar. Cause they aren't activities. They need to be able to be redirected. And you cant redirect something that has no original direction. If that makes sense.

Sent from my ThunderBolt using Tapatalk
 

·
THE MOST INTERESTING MAN IN ANDROID
Joined
·
223 Posts
bgill55 said:
Pretty sure you cant make layout edits with the theme engine. It's based off activities. Which layouts.aren't. Hence whywr can't theme the lockscreen or volume rocker bar. Cause they aren't activities. They need to be able to be redirected. And you cant redirect something that has no original direction. If that makes sense.

Sent from my ThunderBolt using Tapatalk
I have found a couple that work.. mostly for contacts... nothing major tho
 

·
I am The reason you are theming
Joined
·
691 Posts
JsinLegacy said:
I will go out and say yes.. yes you can... BUT... it is extremely limited and I have only found a couple edits that will actually work
For example?

Sent from my ThunderBolt using Tapatalk
 

·
THE MOST INTERESTING MAN IN ANDROID
Joined
·
223 Posts
bgill55 said:
For example?

Sent from my ThunderBolt using Tapatalk
for layout-finger in contacts I have been able to get contacts list item and list section to work ..

I will say that the edits work... the only issue was when selecting a contact in the contact list the app would FC on me.. everything else worked fine and the edit took (sort of)

I will also say I tried many many others that led to fail .. causing the theme to fc every time chosen or causing the apk to not even compile
 

·
Marty Mcfly/Theme Dev
Joined
·
912 Posts
Discussion Starter · #17 ·
But you should be good if you have the id/ done correctly, right? Gonna try it, only have dos layout xmls... the appwidgetpicker for text color, and the drawable/progress_horizontal for the progress bar changes.

If not, there's always metamorphs/side-loading!
 

·
Themer
Joined
·
29 Posts
Stetsonaw said:
But you should be good if you have the id/ done correctly, right? Gonna try it, only have dos layout xmls... the appwidgetpicker for text color, and the drawable/progress_horizontal for the progress bar changes.

If not, there's always metamorphs/side-loading!
IDs get rebuilt when compiling. If u r gonna screw with those u have to make sure they match how it calls out in smali.
 

·
Themer
Joined
·
575 Posts
JsinLegacy said:
just add an id.xml to the values folder.. you can just copy and paste the one from the apk you are trying to get the theme engine to create... or you can just create one and only add the id's you need that the xml... usually this is the easiest way IMO as then you don't have a bunch of unwanted id's in there that might cause confusion..
That is exactly what I ended up doing, except after it compiled, the widget wouldn't load. Guess ill just have to deal with it as it is.
 

·
Marty Mcfly/Theme Dev
Joined
·
912 Posts
Discussion Starter · #20 ·
nmiltner said:
That is exactly what I ended up doing, except after it compiled, the widget wouldn't load. Guess ill just have to deal with it as it is.
You talking about the appwidgetpicker? Not a big deal, as the app isn't part of CM7 anyway. I'll just remove that stuff and have it part of an addon zip.
 
1 - 20 of 20 Posts
Top