Join Today
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 9 of 9
  1. #1
    Member
    Join Date
    Feb 2010
    Posts
    71
    Thanks (Given)
    0
    Thanks (Received)
    0

    Default [project] autorotation to left

    hi all,
    i managed to get autorotation to left. now i have portrait and landscape left, but no landscape right orientation.
    and the goal is to get it to left and right.
    that's what i did:

    i've edited " Wsini.ini" in system\data\ and "autorotateui_rotate.rul" in private\10282bc4\rules\

    Wsini.ini :
    changed "SCR_ROTATION2 0" to "SCR_ROTATION2 180"
    Code:
    WINDOWMODE Color16MA
    AUTOCLEAR 0
    ABSOLUTEFADING
    BLTOFFSCREENBITMAP
    ALLOWPARTIALREDRAWSTORING
    TRANSPARENCY
    ATOMICREDRAWS
    KEYCLICKPLUGIN tactileclickplugin.dll
    KEYCLICKPLUGINFIXED
    S60_KEYROTATOR DISABLED
    
    
    PLUGINS FLICKERBUFFER STD AKNEXTENDEDFADER
    
    [AKNEXTENDEDFADER]
    ID 0x2001B299
    
    
    [SCREEN0]
    SCR_WIDTH1 360
    SCR_HEIGHT1 640
    SCR_ROTATION1 270
    SCR_TWIP_WIDTH1 2235
    SCR_TWIP_HEIGHT1 3973
    S60_SCR_STYLE_NAME1 QHDTOUCH 
    
    SCR_WIDTH2 640
    SCR_HEIGHT2 360
    SCR_ROTATION2 180
    SCR_TWIP_WIDTH2 3973
    SCR_TWIP_HEIGHT2 2235
    S60_SCR_SOFTKEY_LOCATION2 right
    S60_SCR_STYLE_NAME2 QHDTOUCH 
    
    // Touch compatibility mode (virtual keypad)
    SCR_WIDTH3 240
    SCR_HEIGHT3 320
    SCR_ROTATION3 270
    SCR_LEFT3 60
    SCR_TWIP_WIDTH3 1490
    SCR_TWIP_HEIGHT3 1987
    S60_SCR_STYLE_NAME3 QVGACOMPA
    
    // QHD Portrait TOUCH
    S60_HWSTATE_KEYCODE0 EKeyDeviceB
    S60_HWSTATE_SCREENMODE0 1		
    S60_HWSTATE_ALT_SCREENMODE0 2
    
    // QHD Landscape TOUCH
    S60_HWSTATE_KEYCODE1 EKeyDeviceA
    S60_HWSTATE_SCREENMODE1 2		
    S60_HWSTATE_ALT_SCREENMODE1 1
    
    
    FADER AknExtendedFader
    autorotateui_rotate.rul :
    changed "DisplayRightUp" to "DisplayLeftUp" (under "Rotate UI to landscape")
    Code:
    <!--
    * ============================================================================
    * Name    : autorotateui_rotate.rul
    * Part of   : Product concept framework
    * Description : Context framework script file for rotating views
    * Version   : %version: 1 % << Don't touch! Updated by Synergy at check-out.
    
    * Copyright 2008 Nokia. All rights reserved.
    * This material, including documentation and any related computer
    * programs, is protected by copyright controlled by Nokia. All
    * rights are reserved. Copying, including reproducing, storing,
    * adapting or translating, any or all of this material requires the
    * prior written consent of Nokia. This material also contains
    * confidential information which may not be disclosed to others
    * without the prior written consent of Nokia.
    * ============================================================================
    -->
    <!--
    ...
    Description:
      This rule script defines when to rotate UI and when not.
      
    Feature:
      autorotateui
      
    Dependencies:
      autorotateui_init.rul
      autorotateui_activation.rul
    ...
    -->
    <script xmlns="http://www.nokia.com/ns/cep/script/2.0/"
    xmlns:cep="http://www.nokia.com/ns/cep/2.0/">
    
    <!--
    ...
    Description:
      If the following pre-conditions are met, do nothing.
    ...
    -->
      <if>
        <or>
          <equals> <!-- Autorotate UI feature is currently disabled -->
            <contextRef source='Feature' type='Autorotate.UI' value='Disabled'/>
          </equals>
    
          <!-- Turning interaction is currently 'Off' -->
          <equals>
            <contextRef source='Sensor' type='Setting.TurningInteraction.AutoRotation'/>
            <string>Off</string>
          </equals>
        </or>
        <actions>
          <!-- Do nothing -->
          <!-- DEBUG <publishContext> <contextRef source="Test" type="Log" value="autorotateui_rotate.rul - 01"/> </publishContext> -->
        </actions>
      </if>
    
    <!--
    ...
    Description:
      Qwerty flip open - rotate UI to always to landscape.
    ...
    -->
      <elseIf>
        <!-- Qwerty flip is now open -->
        <contextUpdated>
          <contextRef source='Device' type='Qwerty' value='Open'/>
        </contextUpdated>
        <actions>
          <!-- DEBUG <publishContext> <contextRef source="Test" type="Log" value="autorotateui_rotate.rul - 02"/> </publishContext> -->
    
          <!-- Switch to 'Alternate' mode (Landscape) -->
          <Orientation Mode='Alternate'/>
        </actions>
      </elseIf>
    
    <!--
    ...
    Description:
      Rotate UI to landscape.
    ...
    -->
      <elseIf>
        <!-- New orientation event is reveived from sensor source with value 'DisplayLeftUp' -->
        <contextUpdated>
          <contextRef source='Sensor' type='Event.Orientation' value='DisplayLeftUp'/>
        </contextUpdated>
        <actions>
          <!-- DEBUG <publishContext> <contextRef source="Test" type="Log" value="autorotateui_rotate.rul - 03"/> </publishContext> -->
    
          <!-- Switch to 'Alternate' mode (Landscape) -->
          <Orientation Mode='Alternate'/>
        </actions>
      </elseIf>
    
    <!--
    ...
    Description:
      Rotate UI to portrait, exception with Qwerty slide open 
    ...
    -->
      <elseIf>
        <!-- New orientation event is reveived from sensor source with value 'DisplayUp' -->
        <!-- Exception, qwerty slide must be closed -->
        <and>
          <contextUpdated>
            <contextRef source='Sensor' type='Event.Orientation' value='DisplayUp'/>
          </contextUpdated>
          <equals>
            <contextRef source='Device' type='Qwerty' value='Closed'/>
          </equals>
        </and>
        <actions>
          <!-- DEBUG <publishContext> <contextRef source="Test" type="Log" value="autorotateui_rotate.rul - 04"/> </publishContext> -->
    
          <!-- Switch to 'Normal' mode (Portrait) -->
          <Orientation Mode='Normal'/>
        </actions>
      </elseIf>
    
    </script>
    works fine, but no rotation to right.


    maybe it's possible to add a 3rd screenorientation to Wsini.ini and a new rule to autorotateui_rotate.rul for landscape left.
    but i don't know how to associate them with each other...
    anyone has an idea?

    sorry for my poor english

  2. #2
    Senior Member
    Join Date
    Aug 2009
    Posts
    275
    Thanks (Given)
    0
    Thanks (Received)
    0

    Default Re: [project] autorotation to left

    can you show screen shoots ?

    i think this is a modding sceene topic

  3. #3
    Member
    Join Date
    Feb 2010
    Posts
    71
    Thanks (Given)
    0
    Thanks (Received)
    0

    Default Re: [project] autorotation to left

    i tried it out and it works, but i changed it back because if i opened querty keyboard on my n97 the screen was upside down, and that's not really handy... that's a reason why i search for a way to get both, left and right.
    also the screen looks exactly the same, except that it's turned to left, so i don't know if it's usefull to post screenshots..

  4. #4
    Member
    Join Date
    Feb 2010
    Posts
    34
    Thanks (Given)
    0
    Thanks (Received)
    0

    Default Re: [project] autorotation to left

    Hey.
    I had just an idea, let me see if i can explain:

    What if we add one more block of "settings" in Wsini.ini

    For example:

    Code:
    [SCREEN0]
    SCR_WIDTH1 360
    SCR_HEIGHT1 640
    SCR_ROTATION1 270
    SCR_TWIP_WIDTH1 2235
    SCR_TWIP_HEIGHT1 3973
    S60_SCR_STYLE_NAME1 QHDTOUCH 
    
    SCR_WIDTH2 640
    SCR_HEIGHT2 360
    SCR_ROTATION2 180
    SCR_TWIP_WIDTH2 3973
    SCR_TWIP_HEIGHT2 2235
    S60_SCR_SOFTKEY_LOCATION2 right
    S60_SCR_STYLE_NAME2 QHDTOUCH
    and we add

    Code:
    SCR_WIDTH3 640
    SCR_HEIGHT3 360
    SCR_ROTATION3 0
    SCR_TWIP_WIDTH3 3973
    SCR_TWIP_HEIGHT3 2235
    S60_SCR_SOFTKEY_LOCATION3 right
    S60_SCR_STYLE_NAME3 QHDTOUCH
    Haven't changed the SCR_TWIP_WIDTH3, SCR_TWIP_HEIGHT3 values because i don't know what is that, but i think its enough to explain..
    I think this a very interesting project, although i don't know if it will work in my 5800..

    Cheers

  5. #5
    Member
    Join Date
    Mar 2009
    Posts
    38
    Thanks (Given)
    0
    Thanks (Received)
    0

    Default Re: [project] autorotation to left

    Nice Info...

  6. #6
    Senior Member
    Join Date
    Oct 2009
    Posts
    507
    Thanks (Given)
    0
    Thanks (Received)
    1

    Default Re: [project] autorotation to left

    Quote Originally Posted by bls.pt
    Haven't changed the SCR_TWIP_WIDTH3, SCR_TWIP_HEIGHT3 values because i don't know what is that.
    Cheers
    number of pixels, all nokia touch displays are 640x360.

    both WIDTH and HEIGHT can be either 360 or 640, depending on the value of degrees.

  7. #7
    Member
    Join Date
    Feb 2010
    Posts
    71
    Thanks (Given)
    0
    Thanks (Received)
    0

    Default Re: [project] autorotation to left

    Quote Originally Posted by bls.pt
    Hey.
    I had just an idea, let me see if i can explain:

    What if we add one more block of "settings" in Wsini.ini

    For example:

    Code:
    [SCREEN0]
    SCR_WIDTH1 360
    SCR_HEIGHT1 640
    SCR_ROTATION1 270
    SCR_TWIP_WIDTH1 2235
    SCR_TWIP_HEIGHT1 3973
    S60_SCR_STYLE_NAME1 QHDTOUCH 
    
    SCR_WIDTH2 640
    SCR_HEIGHT2 360
    SCR_ROTATION2 180
    SCR_TWIP_WIDTH2 3973
    SCR_TWIP_HEIGHT2 2235
    S60_SCR_SOFTKEY_LOCATION2 right
    S60_SCR_STYLE_NAME2 QHDTOUCH
    and we add

    Code:
    SCR_WIDTH3 640
    SCR_HEIGHT3 360
    SCR_ROTATION3 0
    SCR_TWIP_WIDTH3 3973
    SCR_TWIP_HEIGHT3 2235
    S60_SCR_SOFTKEY_LOCATION3 right
    S60_SCR_STYLE_NAME3 QHDTOUCH
    Haven't changed the SCR_TWIP_WIDTH3, SCR_TWIP_HEIGHT3 values because i don't know what is that, but i think its enough to explain..
    I think this a very interesting project, although i don't know if it will work in my 5800..

    Cheers
    that's exactly what i tryed, also i've added a new rule in autorotateui_rotate.rul for this new block. no success.
    i think the point is to associate the new screenorientation (block) and the new rule somehow.

    Quote Originally Posted by vaterix
    number of pixels, all nokia touch displays are 640x360.

    both WIDTH and HEIGHT can be either 360 or 640, depending on the value of degrees.
    he meant SCR_TWIP_WIDTH and SCR_TWIP_HEIGHT , not SCR_WIDTH and SCR_HEIGHT
    but i don't know what these values are

  8. #8
    Member
    Join Date
    Feb 2010
    Posts
    34
    Thanks (Given)
    0
    Thanks (Received)
    0

    Default Re: [project] autorotation to left

    Well.. First of all i also haven't understand the relationship between wsini and the .rul file.. For me they are not conected each other, but they re defenitly both used in screenrotation.

    We now have 2 possible scenarios (obviously that can be others):

    1. Files are connected between by other "third party" file or
    2. Files are not connect and are called separetely when the sensor is activated..

    About the first scenario, how did you find the files related to screen rotation? Are just this two or can be more??

    About the second, we probably need to change the rul file.. As it seems to be called when sensor activates, i think we need to add one more ELSEIF to the rules, something like

    Code:
    <elseIf>
        <!-- New orientation event is reveived from sensor source with value 'DisplayRightUp' -->
        <contextUpdated>
          <contextRef source='Sensor' type='Event.Orientation' value='DisplayRightUp'/>
        </contextUpdated>
        <actions>
          <!-- DEBUG <publishContext> <contextRef source="Test" type="Log" value="autorotateui_rotate.rul - 04"/> </publishContext> -->
    
          <!-- Switch to 'Alternate' mode (Landscape) -->
          <Orientation Mode='Alternate'/>
        </actions>
      </elseIf>
    What about the files named as "Dependencies" autorotateui_init.rul & autorotateui_activation.rul, have you checked on that too?
    How do you find that the sensor has a value "DisplayLeftUp"? Have a list of other possible values, or it was just a guess?

    Cheers and keep us posted please!

  9. #9
    Senior Member
    Join Date
    Aug 2010
    Posts
    5,193
    Thanks (Given)
    0
    Thanks (Received)
    0

    Default Re: [project] autorotation to left

    Tried this many times.
    This is a FAIL project for me.
    I dont think we'll ever have more orientations.


 

Similar Threads

  1. map loader always show 0MB space left
    By pirates_killer in forum Symbian S60v5 Forum
    Replies: 2
    Last Post: 03-17-2010, 02:37 PM
  2. 540 kb left on my phone memory, what can I do?
    By perfection7 in forum Symbian S60v5 Forum
    Replies: 6
    Last Post: 03-05-2010, 01:59 PM
  3. 2.1 MB of phone memory left, how do I free it up?
    By perfection7 in forum Symbian S60v5 Forum
    Replies: 14
    Last Post: 03-02-2010, 12:17 PM
  4. Scrollbar from Right to Left
    By Nick502 in forum Symbian S60V5 Modding
    Replies: 9
    Last Post: 01-10-2010, 11:18 AM
  5. Left/Right Softkeys for N97?
    By apoptygma in forum Symbian S60v5 Forum
    Replies: 1
    Last Post: 07-13-2009, 03:46 AM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •