5,599,033 Members 32,020 Now Online
XDA Developers Android and Mobile Development Forum

[INQUIRY][DEV] Does SE have Rotation Animation inside stock ROM? Please give info

Tip us?
 
hansip87
Old
#11  
Senior Member - OP
Thanks Meter 1550
Posts: 2,388
Join Date: Jan 2011
Location: Jakarta

 
DONATE TO ME
Quote:
Originally Posted by jjdoctor View Post
Interesting thing I found here regarding Orientation


I grabbed PhoneWindowManager$MyOrientationListener.smali file from HTC android.policy.jar on 2.3.4 and Compared it with Sony SE.. They are mostly Identical but some Lines missing and slightly changed numbers in HTC's file..


In SE its Like This
(Check the BOLD RED Lines..they are missing or changed in HTC's file)
Code:
# direct methods
.method constructor <init>(Lcom/android/internal/policy/impl/PhoneWindowManager;Landroid/content/Context;)V
    .locals 0
    .parameter
    .parameter "context"

    .prologue
    .line 468
    iput-object p1, p0, Lcom/android/internal/policy/impl/PhoneWindowManager$MyOrientationListener;->this$0:Lcom/android/internal/policy/impl/PhoneWindowManager;

    .line 469
    invoke-direct {p0, p2}, Landroid/view/WindowOrientationListener;-><init>(Landroid/content/Context;)V

    .line 470
    return-void
.end method


# virtual methods
.method public onOrientationChanged(I)V
    .locals 3
    .parameter "rotation"

    .prologue
    .line 477
    const-string v0, "WindowManager"

    new-instance v1, Ljava/lang/StringBuilder;

    invoke-direct {v1}, Ljava/lang/StringBuilder;-><init>()V

    const-string v2, "onOrientationChanged, rotation changed to "

    invoke-virtual {v1, v2}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v1

    invoke-virtual {v1, p1}, Ljava/lang/StringBuilder;->append(I)Ljava/lang/StringBuilder;

    move-result-object v1

    invoke-virtual {v1}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object v1

    invoke-static {v0, v1}, Landroid/util/Log;->v(Ljava/lang/String;Ljava/lang/String;)I

    .line 480
    :try_start_0
    iget-object v0, p0, Lcom/android/internal/policy/impl/PhoneWindowManager$MyOrientationListener;->this$0:Lcom/android/internal/policy/impl/PhoneWindowManager;

    iget-object v0, v0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mWindowManager:Landroid/view/IWindowManager;

    const/4 v1, 0x0

    iget-object v2, p0, Lcom/android/internal/policy/impl/PhoneWindowManager$MyOrientationListener;->this$0:Lcom/android/internal/policy/impl/PhoneWindowManager;

    iget v2, v2, Lcom/android/internal/policy/impl/PhoneWindowManager;->mFancyRotationAnimation:I

    invoke-interface {v0, p1, v1, v2}, Landroid/view/IWindowManager;->setRotation(IZI)V
    :try_end_0
    .catch Landroid/os/RemoteException; {:try_start_0 .. :try_end_0} :catch_0

    .line 486
    :goto_0
    return-void

    .line 482
    :catch_0
    move-exception v0

    goto :goto_0
.end method

NOW CHECK IN HTC's file

Code:
# direct methods
.method constructor <init>(Lcom/android/internal/policy/impl/PhoneWindowManager;Landroid/content/Context;)V
    .locals 0
    .parameter
    .parameter "context"

    .prologue
    .line 438
    iput-object p1, p0, Lcom/android/internal/policy/impl/PhoneWindowManager$MyOrientationListener;->this$0:Lcom/android/internal/policy/impl/PhoneWindowManager;

    .line 439
    invoke-direct {p0, p2}, Landroid/view/WindowOrientationListener;-><init>(Landroid/content/Context;)V

    .line 440
    return-void
.end method


# virtual methods
.method public onOrientationChanged(I)V
    .locals 3
    .parameter "rotation"

    .prologue
    .line 447























    :try_start_0
    iget-object v0, p0, Lcom/android/internal/policy/impl/PhoneWindowManager$MyOrientationListener;->this$0:Lcom/android/internal/policy/impl/PhoneWindowManager;

    iget-object v0, v0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mWindowManager:Landroid/view/IWindowManager;

    const/4 v1, 0x0

    iget-object v2, p0, Lcom/android/internal/policy/impl/PhoneWindowManager$MyOrientationListener;->this$0:Lcom/android/internal/policy/impl/PhoneWindowManager;

    iget v2, v2, Lcom/android/internal/policy/impl/PhoneWindowManager;->mFancyRotationAnimation:I

    invoke-interface {v0, p1, v1, v2}, Landroid/view/IWindowManager;->setRotation(IZI)V
    :try_end_0
    .catch Landroid/os/RemoteException; {:try_start_0 .. :try_end_0} :catch_0

    .line 453
    :goto_0
    return-void

    .line 449
    :catch_0
    move-exception v0

    goto :goto_0
.end method
I modded the HTC one to fit the SE lines, named it HTCModdedforSE.zip and attached it for testing.. ont have my SE now...

But just incase I attached the whole android.policy.jar file from HTC Sensation.. You can fully replace SE with HTC one without modding.. maybe that works out...

Give it a go..
the line code that SE have is just for logging purpose, nothing essential mate.
Love to Mod, Love to Experiment

Phone History:
Nokia 6233
Sony Ericsson K700i
SE Xperia X10 Mini Pro
SE Xperia Ray
Motorola RAZR Maxx
Xperia Z Ultra


 
hansip87
Old
#12  
Senior Member - OP
Thanks Meter 1550
Posts: 2,388
Join Date: Jan 2011
Location: Jakarta

 
DONATE TO ME
Quote:
Originally Posted by hansip87 View Post
the line code that SE have is just for logging purpose, nothing essential mate.
As i scan all the code, it is actually depends on native function which resides on libsurfaceflinger.so. So no mod can be done about that unless somebody can crack the .so file. Case closed, thanks for the input.
Love to Mod, Love to Experiment

Phone History:
Nokia 6233
Sony Ericsson K700i
SE Xperia X10 Mini Pro
SE Xperia Ray
Motorola RAZR Maxx
Xperia Z Ultra


The Following User Says Thank You to hansip87 For This Useful Post: [ Click to Expand ]
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes