Attend XDA's Second Annual Developer Conference, XDA:DevCon 2014!
5,728,048 Members 46,412 Now Online
XDA Developers Android and Mobile Development Forum

[THEME][ZIP]Complete Gingerbread theme for 3xx based roms

Tip us?
 
playya
Old
#11  
playya's Avatar
Senior Member
Thanks Meter 1813
Posts: 5,345
Join Date: Jan 2007
Location: Florida

 
DONATE TO ME
Quote:
Originally Posted by TheManii View Post
Code:
.method private final updateClock()V
    .registers 7

    .prologue
    .line 736
    iget-object v0, p0, Lcom/android/server/status/StatusBarPolicy;->mCalendar:Ljava/util/Calendar;

    invoke-static {}, Ljava/lang/System;->currentTimeMillis()J

    move-result-wide v1

    invoke-virtual {v0, v1, v2}, Ljava/util/Calendar;->setTimeInMillis(J)V

    .line 737
    iget-object v0, p0, Lcom/android/server/status/StatusBarPolicy;->mClockData:Lcom/android/server/status/IconData;

    iget-object v1, p0, Lcom/android/server/status/StatusBarPolicy;->mContext:Landroid/content/Context;

    invoke-static {v1}, Landroid/text/format/DateFormat;->getTimeFormat(Landroid/content/Context;)Ljava/text/DateFormat;

    move-result-object v1

    iget-object v2, p0, Lcom/android/server/status/StatusBarPolicy;->mCalendar:Ljava/util/Calendar;

    invoke-virtual {v2}, Ljava/util/Calendar;->getTime()Ljava/util/Date;

    move-result-object v2

    invoke-virtual {v1, v2}, Ljava/text/DateFormat;->format(Ljava/util/Date;)Ljava/lang/String;

    move-result-object v1

    const-string v4, " PM"

    const-string v5, ""

    invoke-virtual {v1, v4, v5}, Ljava/lang/String;->replace(Ljava/lang/CharSequence;Ljava/lang/CharSequence;)Ljava/lang/String;

    move-result-object v1

    const-string v4, " AM"

    const-string v5, ""

    invoke-virtual {v1, v4, v5}, Ljava/lang/String;->replace(Ljava/lang/CharSequence;Ljava/lang/CharSequence;)Ljava/lang/String;

    move-result-object v1

    iput-object v1, v0, Lcom/android/server/status/IconData;->text:Ljava/lang/CharSequence;

    .line 738
    iget-object v0, p0, Lcom/android/server/status/StatusBarPolicy;->mService:Lcom/android/server/status/StatusBarService;

    iget-object v1, p0, Lcom/android/server/status/StatusBarPolicy;->mClockIcon:Landroid/os/IBinder;

    iget-object v2, p0, Lcom/android/server/status/StatusBarPolicy;->mClockData:Lcom/android/server/status/IconData;

    const/4 v3, 0x0

    invoke-virtual {v0, v1, v2, v3}, Lcom/android/server/status/StatusBarService;->updateIcon(Landroid/os/IBinder;Lcom/android/server/status/IconData;Lcom/android/server/status/NotificationData;)V

    .line 739
    return-void
.end method
in services.jar/clock\com\android\server\status\statusbaricon.smal i

I assume you understand how to baksmali and diff it, the AM and PM should be whatever chars your lang uses for AM and PM (if your lang does not use AM PM). It's not the proper way to do it, I never bothered finding out how GB roms do it properly.
Yea if this is for Froyo then its a no go I have been sniffing around this code for a minute and I know its in the services.jar file but can not find the AM/PM indicators anywhere. Thanks for your assistance though... Just to clarify this is the Froyo method right
DeBloat your AOKP/CM10 fast and pain free click here
---------------------------------------------------
"Hey if you can type it you can search it" - Google is your friend - Let me Google that for you
--------------------------------------------------
Proud owner of a Nexus 4 on LiquidSmooth 2.5/Samsung Galaxy S2(AT&T)and Wifi Only Xoom
 
TheManii
Old
#12  
Wiki Admin / Recognized Contributor - OP
Thanks Meter 1505
Posts: 3,370
Join Date: Dec 2010

 
DONATE TO ME
That code is directly from a Streak 5 360 rom, the base should be nearly identical for all V roms (assuming you're in fact talking about a V)

Code:
    const-string v4, " PM"

    const-string v5, ""

    invoke-virtual {v1, v4, v5}, Ljava/lang/String;->replace(Ljava/lang/CharSequence;Ljava/lang/CharSequence;)Ljava/lang/String;

    move-result-object v1

    const-string v4, " AM"

    const-string v5, ""

    invoke-virtual {v1, v4, v5}, Ljava/lang/String;->replace(Ljava/lang/CharSequence;Ljava/lang/CharSequence;)Ljava/lang/String;

    move-result-object v..
is the main functional part of the mod, but I havnt touched it in nearly a year so my memory of the specifics isnt very good
XDA Wiki Moderator
Nexus 4: Stock 4.4.4 (KTU84P) 2013 N7: Stock 4.4.4 (KTU84P)
iTouch 5G: 6.1.2 (10B146) Surface Pro 2: Win8.1u1 (6.3.9600.17085.amd64fre.winblue_gdr.140330-1035)
The Following User Says Thank You to TheManii For This Useful Post: [ Click to Expand ]
 
playya
Old
#13  
playya's Avatar
Senior Member
Thanks Meter 1813
Posts: 5,345
Join Date: Jan 2007
Location: Florida

 
DONATE TO ME
Quote:
Originally Posted by TheManii View Post
That code is directly from a Streak 5 360 rom, the base should be nearly identical for all V roms (assuming you're in fact talking about a V)

Code:
    const-string v4, " PM"

    const-string v5, ""

    invoke-virtual {v1, v4, v5}, Ljava/lang/String;->replace(Ljava/lang/CharSequence;Ljava/lang/CharSequence;)Ljava/lang/String;

    move-result-object v1

    const-string v4, " AM"

    const-string v5, ""

    invoke-virtual {v1, v4, v5}, Ljava/lang/String;->replace(Ljava/lang/CharSequence;Ljava/lang/CharSequence;)Ljava/lang/String;

    move-result-object v..
is the main functional part of the mod, but I havnt touched it in nearly a year so my memory of the specifics isnt very good
Trying to do the mod for a Gingerbread based phone - Galaxy 2 actually and I was just mulling around looking for the fix and thought I might asked you to see if you had knowledge of it. The services files are definitely different at closer look but was hoping for some more insight... Like I said thanks anyway and sorry if I wasted any of your time
DeBloat your AOKP/CM10 fast and pain free click here
---------------------------------------------------
"Hey if you can type it you can search it" - Google is your friend - Let me Google that for you
--------------------------------------------------
Proud owner of a Nexus 4 on LiquidSmooth 2.5/Samsung Galaxy S2(AT&T)and Wifi Only Xoom
 
TheManii
Old
#14  
Wiki Admin / Recognized Contributor - OP
Thanks Meter 1505
Posts: 3,370
Join Date: Dec 2010

 
DONATE TO ME
If you're on a GB rom already I dont believe that'll help, you'll need to figure out what code was removed/disabled then, as GB natively includes the ability to remove the AM/PM indicators.
XDA Wiki Moderator
Nexus 4: Stock 4.4.4 (KTU84P) 2013 N7: Stock 4.4.4 (KTU84P)
iTouch 5G: 6.1.2 (10B146) Surface Pro 2: Win8.1u1 (6.3.9600.17085.amd64fre.winblue_gdr.140330-1035)
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes


XDA PORTAL POSTS

Pale Moon Browser Ported to Android

Having a wide choice of third party applications is one of the most beautiful things that Android has to … more

Partial Android Wear Source Uploaded to AOSP

2014 is certainly shaping up to be theyear of the wearables. And thanks to its innovative … more

Street Panorama Combines Google Maps and Street View into One App

Google Maps is a must have application forevery amateur world explorer. … more

XDA Behind the Scenes, Part 3

This is the last part of a series of articles that reveals some of the processes, technology, and systems that … more