yashsingh1/xdaforums huggingface dataset:
[Galaxy S II Android Development] remuntada78:
I searched for null pointer exception and i found that a null pointer exception means that one of the variables you are passing is null, but where is this null variable in my code?

thanks in advance
[Galaxy S II Android Development] CNexus:
Doesn't setStatusbarExpandedColor require an integer parameter for the color as well?
[Galaxy S II Android Development] remuntada78:
thanks for the reply, but i don't undestand what you mean:silly:, can you give more information?

thanks in advance
[Galaxy S II Android Development] Goldie:
No it doesnt it gets the color in the method
[Galaxy S II Android Development] Goldie:
It may be that you need to check-cast the view to a layout to match the layout type of your header. Then use setbackgroundcolor. Otherwise no clue. It should and does work for me. Sure that id is right and exists in the layout xml?
[Galaxy S II Android Development] Goldie:
Don't ask! Try!
[Galaxy S II Android Development] remuntada78:
I tried it ,but i got a strange error when compile, in fact if i add this

const v15, 0x3f7d70a4

invoke-virtual {v14, v15}, Landroid/view/View;->setAlpha(F)V

.line 1427
[COLOR="Red"] iget v15, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mOnGoingBGColor:I[/COLOR]

invoke-virtual {v14, v15}, Landroid/view/View;->setBackgroundColor(I)V

.line 1428
move-object/from16 v0, p0

iget-object v15, v0, Lcom/android/systemui/statusbar/BaseStatusBar;->mOngoingNotifications:Lcom/android/systemui/statusbar/policy/NotificationRowLayout;

invoke-virtual {v15, v14, v4}, Landroid/view/ViewGroup;->addView(Landroid/view/View;I)V

i got this

but if i put again this code const/high16 v15, -0x100 the compile goes fine.

why this?
[Galaxy S II Android Development] Goldie:
Look at line below...yours says iget v15, p0. Lines below.... move p0 to v0 then iget v15, v0
[Galaxy S II Android Development] remuntada78:
i'm sorry i can't understand how to solve it
[Galaxy S II Android Development] Goldie:
You say this...

iget v15, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mOnGoingBGColor:I

Below you see you cannot do that...

iget-object v15, v0, Lcom/android/systemui/statusbar/BaseStatusBar;->mOngoingNotifications:Lcom/android/systemui/statusbar/policy/NotificationRowLayout;

See v0 not p0. So you need....

move-object/from16 v0, p0

iget v15, v0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mOnGoingBGColor:I
[Galaxy S II Android Development] remuntada78:
ohh yes :p i understand. thanks

little op . you already have the S5 ? What do you think about it?
[Galaxy S II Android Development] Goldie:
Its very nice. Feels solid like s2 did. The floating toolbox for app shortcuts is cool too
[Galaxy S II Android Development] remuntada78:
in my method setOnGoingBGColor()V this line iput v1, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mOnGoingBGColor:I gave me this error

W/dalvikvm( 2348): VFY: attempt to access field in non-reference type 15

W/dalvikvm( 2348): VFY: rejecting opcode 0x59 at 0x000f

W/dalvikvm( 2348): VFY: rejected Lcom/android/systemui/statusbar/phone/PhoneStatusBar;.setOnGoingBGColor ()V

W/dalvikvm( 2348): Verifier rejected class Lcom/android/systemui/statusbar/phone/PhoneStatusBar;

W/dalvikvm( 2348): Class init failed in newInstance call (Lcom/android/systemui/statusbar/phone/PhoneStatusBar;)
[Galaxy S II Android Development] remuntada78:
[MENTION=3065070]Goldie[/MENTION] i'm sorry i can't understand why it not work, i cheked and compared my code with your in the guide , it seems right, can you give some information?:D
[Galaxy S II Android Development] Goldie:
Huh....you had that working already...What happened?
[Galaxy S II Android Development] remuntada78:
Really?i don't remember:eek:, it's my first time i use a method like this, i mean with iput in the code
[Galaxy S II Android Development] Goldie:
Why did you put that? This was working for you....
[Galaxy S II Android Development] remuntada78:
i've already used this way like this

.method setOnGoingBGColor()V
.locals 6

iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mStatusBarWindow:Lcom/android/systemui/statusbar/phone/StatusBarWindowView;

const v1, 0x7f0d00e7 [COLOR="Red"]<--this is onGoingItems's id[/COLOR]

invoke-virtual {v0, v1}, Lcom/android/systemui/statusbar/phone/StatusBarWindowView;->findViewById(I)Landroid/view/View;

move-result-object v0

check-cast v0, Landroid/view/View;

iget-object v2, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mContext:Landroid/content/Context;

invoke-virtual {v2}, Landroid/content/Context;->getContentResolver()Landroid/content/ContentResolver;

move-result-object v2

const-string v3, "ongoing_bg_color"

const v4, -0x100

invoke-static {v2, v3, v4}, Landroid/provider/Settings$System;->getInt(Landroid/content/ContentResolver;Ljava/lang/String;I)I

move-result v2

invoke-virtual {v0, v2}, Landroid/view/View;->setBackgroundColor(I)V

return-void
.end method

and it not work i also tried changing last line invoke-virtual with iput v2, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mOnGoingBGColor:I and put the relative iget but it also not work.

the only way that work for me is like this

changing this

move-result-object v15

if-nez v15, :cond_e

.line 1426
const v15, 0x3f7d70a4

invoke-virtual {v14, v15}, Landroid/view/View;->setAlpha(F)V

.line 1427
[COLOR="Red"] const/high16 v15, -0x100[/COLOR]

invoke-virtual {v14, v15}, Landroid/view/View;->setBackgroundColor(I)V

.line 1428
move-object/from16 v0, p0

iget-object v15, v0, Lcom/android/systemui/statusbar/BaseStatusBar;->mOngoingNotifications:Lcom/android/systemui/statusbar/policy/NotificationRowLayout;

invoke-virtual {v15, v14, v4}, Landroid/view/ViewGroup;->addView(Landroid/view/View;I)V

to this

move-result-object v15

if-nez v15, :cond_e

.line 1426
const v15, 0x3f7d70a4

invoke-virtual {v14, v15}, Landroid/view/View;->setAlpha(F)V

.line 1427
[COLOR="Red"]iget-object v9, v0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mContext:Landroid/content/Context;

invoke-virtual {v9}, Landroid/content/Context;->getContentResolver()Landroid/content/ContentResolver;

move-result-object v9

const-string v10, "ongoing_bg_color"

const v15, -0x100

invoke-static {v9, v10, v15}, Landroid/provider/Settings$System;->getInt(Landroid/content/ContentResolver;Ljava/lang/String;I)I

move-result v15[/COLOR]

invoke-virtual {v14, v15}, Landroid/view/View;->setBackgroundColor(I)V

but with this way i need to restart the device
[Galaxy S II Android Development] remuntada78:
after some test,both above ways work without restart the device, they works in this way:

i set color for ongoing notification background and it appears like i set,

if i change color for the same ongoing notification it appears like for first set, it change only with new ongoing notification

is this the correct way to work for ongoing notification?
[Galaxy S II Android Development] maskerwsk:
Hi Guys.

Trying to change the text colour of the battery percentage.

this is what ive done so far,Added the Red bit. (BatteryController.smali)

invoke-virtual {v11, v4}, Ljava/util/ArrayList;->get(I)Ljava/lang/Object;

move-result-object v10

check-cast v10, Landroid/widget/TextView;

.line 94
.local v10, v:Landroid/widget/TextView;
move-object/from16 v0, p0

iget-object v11, v0, Lcom/android/systemui/statusbar/policy/BatteryController;->mContext:Landroid/content/Context;

const v12, 0x7f0a0027

const/4 v13, 0x1

new-array v13, v13, [Ljava/lang/Object;

const/4 v14, 0x0

invoke-static {v7}, Ljava/lang/Integer;->valueOf(I)Ljava/lang/Integer;

move-result-object v15

aput-object v15, v13, v14

invoke-virtual {v11, v12, v13}, Landroid/content/Context;->getString(I[Ljava/lang/Object;)Ljava/lang/String;

move-result-object v11

invoke-virtual {v10, v11}, Landroid/widget/TextView;->setText(Ljava/lang/CharSequence;)V

[COLOR="Red"]	invoke-virtual {v10}, Lcom/android/systemui/statusbar/policy/BatteryController;->getContext()Landroid/content/Context;

move-result-object v13

invoke-virtual {v13}, Landroid/content/Context;->getContentResolver()Landroid/content/ContentResolver;

move-result-object v13

const-string v14, "batt_text_color"

const v15, -0xcc4a1a

invoke-static {v13, v14, v15}, Landroid/provider/Settings$System;->getInt(Landroid/content/ContentResolver;Ljava/lang/String;I)I

move-result v13

invoke-virtual {v10, v13}, Lcom/android/systemui/statusbar/policy/BatteryController;->setTextColor(I)V[/COLOR]

.line 92
add-int/lit8 v4, v4, 0x1[/HIDE]

Al compiles fine but doesnt have any effect, Any ideas?

Thanks.
[Galaxy S II Android Development] CNexus:
Does it change when you do a full reboot/hot reboot? It could just be that it's not updating instantly.
[Galaxy S II Android Development] maskerwsk:
No, no change after reboot
[Galaxy S II Android Development] CNexus:
Then either a) you're not changing it in the right place or b) changing the wrong variable
[Galaxy S II Android Development] maskerwsk:
hello again.

just implemented a new method to show/hide toggles.

code works fine but requires reboot to update.

here is my method:

.method maskerwsk_hide_toggles()V
.locals 6

iget-object v1, p0, Lcom/android/systemui/SystemUI;->mContext:Landroid/content/Context;

invoke-virtual {v1}, Landroid/content/Context;->getContentResolver()Landroid/content/ContentResolver;

move-result-object v1

const-string v2, "display_galactus_toggle"

const/4 v3, 0x1

invoke-static {v1, v2, v3}, Landroid/provider/Settings$System;->getInt(Landroid/content/ContentResolver;Ljava/lang/String;I)I

move-result v3

if-nez v3, :cond_0

const v3, 0x8

:cond_0
iget-object v5, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mStatusBarWindow:Lcom/android/systemui/statusbar/phone/StatusBarWindowView;

const p0, 0x7f0700d4

invoke-virtual {v5, p0}, Lcom/android/systemui/statusbar/phone/StatusBarWindowView;->findViewById(I)Landroid/view/View;

move-result-object v4

invoke-virtual {v4, v3}, Landroid/widget/HorizontalScrollView;->setVisibility(I)V

return-void
.end method

I want to add an observer to this so I can update without reboot.

ive copied an exsisting observer and changed name and references inside the file to ToggleObserver.

how can I mod my above code to use the new observer?
[Galaxy S II Android Development] remuntada78:
.method public notificationpanelbackground()V
.locals 5

iget-object v1, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mContext:Landroid/content/Context;

invoke-virtual {v1}, Landroid/content/Context;->getContentResolver()Landroid/content/ContentResolver;

move-result-object v1

const-string v2, "enable_disable_bg_color"

const/4 v3, 0x1

invoke-static {v1, v2, v3}, Landroid/provider/Settings$System;->getInt(Landroid/content/ContentResolver;Ljava/lang/String;I)I

move-result v1

if-eqz v1, :cond_enable_disable

iget-object v1, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mContext:Landroid/content/Context;

invoke-virtual {v1}, Landroid/content/Context;->getContentResolver()Landroid/content/ContentResolver;

move-result-object v1

const-string v2, "notification_panel_bg_chooser"

const v3, 0x0

invoke-static {v1, v2, v3}, Landroid/provider/Settings$System;->getInt(Landroid/content/ContentResolver;Ljava/lang/String;I)I

move-result v1

const v2, 0x1

if-eq v1, v2, :cond_0

const v2, 0x2

if-eq v1, v2, :cond_1

const v2, 0x3

if-eq v1, v2, :cond_2

const v2, 0x4

if-eq v1, v2, :cond_3

const v2, 0x5

if-eq v1, v2, :cond_4

const v2, 0x6

if-eq v1, v2, :cond_5

const v2, 0x7

if-eq v1, v2, :cond_6

const v2, 0x8

if-eq v1, v2, :cond_7

const v2, 0x9

if-eq v1, v2, :cond_8

const v2, 0x7f020071

goto :goto_0

:cond_0
const v2, 0x7f020267

goto :goto_0

:cond_1
const v2, 0x7f020268

goto :goto_0

:cond_2
const v2, 0x7f020269

goto :goto_0

:cond_3
const v2, 0x7f02029c

goto :goto_0

:cond_4
const v2, 0x7f02029d

goto :goto_0

:cond_5
const v2, 0x7f021081

goto :goto_0

:cond_6
const v2, 0x7f021080

goto :goto_0

:cond_7
const v2, 0x7f02107e

goto :goto_0

:cond_8
const v2, 0x7f02107f

:goto_0
iget-object v3, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mNotificationPanel:Landroid/view/View;

invoke-virtual {v3, v2}, Landroid/view/View;->setBackgroundResource(I)V

:cond_enable_disable
iget-object v1, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mContext:Landroid/content/Context;

invoke-virtual {v1}, Landroid/content/Context;->getContentResolver()Landroid/content/ContentResolver;

move-result-object v1

const-string v2, "noti_panel_bg_color"

const v3, -0x100

invoke-static {v1, v2, v3}, Landroid/provider/Settings$System;->getInt(Landroid/content/ContentResolver;Ljava/lang/String;I)I

move-result v4

iget-object v3, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mNotificationPanel:Landroid/view/View;

invoke-virtual {v3, v4}, Landroid/view/View;->setBackgroundColor(I)V

return-void
.end method

what is wrong in this code?i tried to add a checkbox that when is checked i can choose for change background color and when is not checked i can choose for change background image,but when is checked or not cheched work only the change color

thanks in advance
[Galaxy S II Android Development] Goldie:
Your goto after each of the 8 conds goes to the code to setbackground which then runs through to the code to color!!

You need a goto :goto_new after setbackgroundresource and :goto_new just before return-void

Sent from my AllianceROM'd S5
[Galaxy S II Android Development] josephpatrick:
Removing favorites from stock dialer

Does anyone know how to remove the favorites tab from the stock Samsung dialer? Have tried a lot of things in smali but my attempt is more like a trial and error method. Could not find anything in the xml files, so targetted smali files, still not luck.

Am not a coding person so need assistance. Trying to understand how the layout is defined. If it is being picked up from xml files, which file is it?
[Galaxy S II Android Development] Mr0lala:
Colorpicker for Network meter

Hi,

I try to make custom color for network meter on CM11 but I can't find similar code like: setText(Ljava/lang/CharSequence;)V to make this, any suggestion? I attachments this code..... any can help me? Sorry my bad English
[Galaxy S II Android Development] Goldie:
You didnt look very hard....

Sent from my AllianceROM'd S5
[Galaxy S II Android Development] Mr0lala:
Sorry, at the first time I don't think it right code because it's not look like your guide, but after read all pages I see I wrong, and I did it :highfive: :good:

Thank you so much, excellent guide :good::fingers-crossed:
[Galaxy S II Android Development] remuntada78:
[MENTION=3065070]Goldie[/MENTION].

Hi Goldie i'm trying to to understand this line

invoke-virtual {v0, v2, p2}, Landroid/widget/RemoteViews;->setTextViewText(ILjava/lang/CharSequence;)V

i'm comparing it whit this

invoke-virtual {v3, v4}, Landroid/widget/TextView;->setText(Ljava/lang/CharSequence;)V

can you tell me if i'm on the right way?i think v0 of first code corresponds to v3 of second and v2 of first correspond to v4 of second, it's right?
[Galaxy S II Android Development] Goldie:
Remoteviews share many methods. Take a look here...

http://developer.android.com/reference/android/widget/RemoteViews.html

Sent from my AllianceROM'd S5
[Galaxy S II Android Development] remuntada78:
yes I had already read that page , and the part that interests me is that it said "setTextViewText(int viewId, CharSequence text) Equivalent to calling TextView.setText"

i asked fot this 'cause i would like to add code for change text color in this code

.line 928
:cond_35
if-eqz p2, :cond_3d

.line 929
const v2, 0x1020016

invoke-virtual {v0, v2, p2}, Landroid/widget/RemoteViews;->setTextViewText(ILjava/lang/CharSequence;)V
[Galaxy S II Android Development] Goldie:
Then you just need...

invoke-virtual {v0, v2, v3}, Landroid/widget/RemoteViews;->setTextColor{II;}V

Where v3 is your color

Sent from my AllianceROM'd S5
[Galaxy S II Android Development] remuntada78:
it was what i was thinking ,I had a doubt whit p2 ,thanks again:good:
[Galaxy S II Android Development] Goldie:
Edited my reply. Made a mistake i think

Sent from my AllianceROM'd S5
[Galaxy S II Android Development] remuntada78:
again me, i had issue in recompiling with setTextColor{II;}V so i changed it with setTextColor(II)V

i added this red code

.line 928
:cond_35
if-eqz p2, :cond_3d

.line 929
const v2, 0x1020016

invoke-virtual {v0, v2, p2}, Landroid/widget/RemoteViews;->setTextViewText(ILjava/lang/CharSequence;)V

[COLOR="Red"] invoke-virtual {v12}, Landroid/widget/RemoteViews;->getContext()Landroid/content/Context;

move-result-object v12

invoke-virtual {v12}, Landroid/content/Context;->getContentResolver()Landroid/content/ContentResolver;

move-result-object v12

const-string v13, "title_text_color"

const v14, -0x1

invoke-static {v12, v13, v14}, Landroid/provider/Settings$System;->getInt(Landroid/content/ContentResolver;Ljava/lang/String;I)I

move-result v12

invoke-virtual {v0, v2, v12}, Landroid/widget/RemoteViews;->setTextColor(II)V[/COLOR]

and i got this error

I/dalvikvm( 2207): Could not find method android.widget.RemoteViews.getContext, referenced from method android.app.Notification.setLatestEventInfo

W/dalvikvm( 2207): VFY: unable to resolve virtual method 37031: Landroid/widget/RemoteViews;.getContext ()Landroid/content/Context;

D/dalvikvm( 2207): VFY: replacing opcode 0x6e at 0x003d

E/AndroidRuntime( 3035): *** FATAL EXCEPTION IN SYSTEM PROCESS: UsbDeviceManager

E/AndroidRuntime( 3035): java.lang.NoSuchMethodError: android.widget.RemoteViews.getContext

E/AndroidRuntime( 3035):	at android.app.Notification.setLatestEventInfo(Notification.java:929)

E/AndroidRuntime( 3035):	at com.android.server.usb.UsbDeviceManager$UsbHandler.updateUsbNotification(UsbDeviceManager.java:871)

E/AndroidRuntime( 3035):	at com.android.server.usb.UsbDeviceManager$UsbHandler.handleMessage(UsbDeviceManager.java:743)

E/AndroidRuntime( 3035):	at android.os.Handler.dispatchMessage(Handler.java:99)

E/AndroidRuntime( 3035):	at android.os.Looper.loop(Looper.java:137)

E/AndroidRuntime( 3035):	at android.os.HandlerThread.run(HandlerThread.java:60)

D/CircleLockScreen( 3035): cursor.getInt(0) = 0

D/CircleLockScreen( 3035): cursor.getInt(0) = 0

D/CircleLockScreen( 3035): mChecked = 111

D/CircleLockScreen( 3035): onRefreshBatteryInfo() showPatteryInfo: false pluggedIn: false batteryLevel: 100

D/ClockWidget( 3035): isDualClock : false

D/ClockWidget( 3035): refreshTime()
[Galaxy S II Android Development] Goldie:
well yeah....remoteviews doesnt have getcontext method so you will need a different way for context

Sent from my AllianceROM'd S5
[Galaxy S II Android Development] remuntada78:
i was editing my post right now , i think to change invoke-virtual {v12}, Landroid/widget/RemoteViews;->getContext()Landroid/content/Context; invoke-virtual {v12}, Landroid/view/View;->getContext()Landroid/content/Context;

edit:invoke-virtual {v12}, Landroid/view/View;->getContext()Landroid/content/Contex not work

error

W/dalvikvm( 2206): VFY: 'this' arg 'Ljava/lang/CharSequence;' not instance of 'Landroid/view/View;'

W/dalvikvm( 2206): VFY: rejecting opcode 0x6e at 0x003d

W/dalvikvm( 2206): VFY: rejected Landroid/app/Notification;.setLatestEventInfo (Landroid/content/Context;Ljava/lang/CharSequence;Ljava/lang/CharSequence;Landroid/app/PendingIntent;)V

W/dalvikvm( 2206): Verifier rejected class Landroid/app/Notification;
[Galaxy S II Android Development] remuntada78:
i tried with this code

:cond_35
if-eqz p2, :cond_3d

.line 929
const v2, 0x1020016

invoke-virtual {v0, v2, p2}, Landroid/widget/RemoteViews;->setTextViewText(ILjava/lang/CharSequence;)V

[COLOR="Red"]iget-object v12, p0, Landroid/app/Notification;->contentView:Landroid/widget/RemoteViews;

invoke-virtual {v12}, Landroid/widget/RemoteViews;->getContext()Landroid/content/Context;

move-result-object v12

invoke-virtual {v12}, Landroid/content/Context;->getContentResolver()Landroid/content/ContentResolver;

move-result-object v12

const-string v13, "title_text_color"

const v14, -0x1

invoke-static {v12, v13, v14}, Landroid/provider/Settings$System;->getInt(Landroid/content/ContentResolver;Ljava/lang/String;I)I

move-result v12

invoke-virtual {v0, v2, v12}, Landroid/widget/RemoteViews;->setTextColor(II)V[/COLOR]

but i got the same error

I/dalvikvm( 2207): Could not find method android.widget.RemoteViews.getContext, referenced from method android.app.Notification.setLatestEventInfo

W/dalvikvm( 2207): VFY: unable to resolve virtual method 37031: Landroid/widget/RemoteViews;.getContext ()Landroid/content/Context;

D/dalvikvm( 2207): VFY: replacing opcode 0x6e at 0x003f

how can i solve it?
[Galaxy S II Android Development] Goldie:
Like i said remoteviews doesnt have getcontext. That code is same as last...calling getcontext from remoteviews.

Look at other lines in the file for context

Sent from my AllianceROM'd S5
[Galaxy S II Android Development] remuntada78:
no it's not the same i added this line

iget-object v12, p0, Landroid/app/Notification;->contentView:Landroid/widget/RemoteViews;

now i look:good:
[Galaxy S II Android Development] Goldie:
No but i mean it is still looking for getcontext in remoteviews which does not exist

Sent from my AllianceROM'd S5
[Galaxy S II Android Development] remuntada78:
i'm not sure if i already worked with this way, can you give me an example?
[Galaxy S II Android Development] Goldie:
No because i dont have the files. Just search the file for context and see how it is done elsewhere

Sent from my AllianceROM'd S5
[Galaxy S II Android Development] remuntada78:
changed the code like this

:cond_35
if-eqz p2, :cond_3d

.line 929
const v2, 0x1020016

invoke-virtual {v0, v2, p2}, Landroid/widget/RemoteViews;->setTextViewText(ILjava/lang/CharSequence;)V

[COLOR="Red"]invoke-virtual {p1}, Landroid/content/Context;->getContentResolver()Landroid/content/ContentResolver;

move-result-object v7

const-string v8, "title_text_color"

const v9, -0x1

invoke-static {v7, v8, v9}, Landroid/provider/Settings$System;->getInt(Landroid/content/ContentResolver;Ljava/lang/String;I)I

move-result v7

invoke-virtual {v0, v2, v7}, Landroid/widget/RemoteViews;->setTextColor(II)V[/COLOR]

and i got this error

W/dalvikvm( 2206): VFY: attempt to access field in non-reference type 2

W/dalvikvm( 2206): VFY: rejecting opcode 0x53 at 0x0056

W/dalvikvm( 2206): VFY: rejected Landroid/app/Notification;.setLatestEventInfo (Landroid/content/Context;Ljava/lang/CharSequence;Ljava/lang/CharSequence;Landroid/app/PendingIntent;)V

W/dalvikvm( 2206): Verifier rejected class Landroid/app/Notification;

:eek:i'm going crazy:eek:
[Galaxy S II Android Development] remuntada78:
Hi Goldie with the above mod i want to implement change color for notification text.

Can you drive me in the right way?

thanks in advance

edit:i solved, thanks anyway
[Galaxy S II Android Development] gerryS2:
Hi, I would to create a SettingsObserve for the QuickSettingsButton, any help?

I have insert a observe code like this in .method public constructor <init>(Landroid/content/Context;Landroid/util/AttributeSet;IIIIII)V:

iget-object v0, p0, Lcom/android/systemui/statusbar/policy/quicksetting/QuickSettingButton;->mContext:Landroid/content/Context;

invoke-virtual {v0}, Landroid/content/Context;->getContentResolver()Landroid/content/ContentResolver;

move-result-object v0

const-string v1, "background_toggle_list"

invoke-static {v1}, Landroid/provider/Settings$System;->getUriFor(Ljava/lang/String;)Landroid/net/Uri;

move-result-object v1

iget-object v2, p0, Lcom/android/systemui/statusbar/policy/quicksetting/QuickSettingButton;->mProvisioningObserver:Landroid/database/ContentObserver;

invoke-virtual {v0, v1, v3, v2}, Landroid/content/ContentResolver;->registerContentObserver(Landroid/net/Uri;ZLandroid/database/ContentObserver;)V

return-void
.end method

Changes occur only if I change the button icons or restart the systemui. Is there a way to have changes on fly like the icon?
[Galaxy S II Android Development] remuntada78:
i think this http://xdaforums.com/showpost.php?p=50961314&postcount=527 can help you
[Galaxy S II Android Development] remuntada78:
excuse my insistence, any news for my trouble?
[Galaxy S II Android Development] remuntada78:
Can anyone help me please:p?