Menu

Main Menu
Talk Get Daily Search

Member's Online

    User Name
    Password

    [Patch] Unlock the rotation of most stock applications

    Reply
    Page 1 of 7 | 1   2     3   | Next | Last
    Vesuri | # 1 | 2012-07-11, 10:20 | Report

    Most of the MeeGo 1.2 Harmattan stock applications (excluding a few like Facebook, Twitter, AccuWeather, Maps and Drive) in the Nokia N9 and the Nokia N950 are written using the libmeegotouch UI library. Libmeegotouch allows the orientation of the application to be locked so that it does not rotate freely when the device is rotated. Most of the applications are locked to portrait to emphasize portrait as the primary device orientation. Unfortunately this is done on the UI library level so that there is no easy way to unlock the orientation.

    This patch, available from http://vesuri.jormas.com/harmattan/libmeegotouch.html, changes libmeegotouch's MWindow::isOrientationAngleLocked() and MWindow::isOrientationLocked() so that instead of returning the locking value set by the application they return whether the application window's name or class matches one of the names or classes defined by the user in two GConf keys, /meegotouch/orientationlock/names and /meegotouch/orientationlock/classes. Both contain lists of strings, which can
    be set using GConfTool using the [value1,value2,value3] format.

    A pre-built libmeegotouchcore0 package for Harmattan PR1.3 is provided for those who want to try the patch out. When trying out the patch one should notice that the libmeegotouchcore0 package is installed from the com.nokia.maemo Aegis origin by default and cannot be replaced with a package from a less trusted source. Since force removing and reinstalling the package has the potential of rendering the device useless it is not recommended on a device which has a watchdog enabled. Incepting the package will work, but it should be noted that then the package becomes installed from com.nokia.maemo/local, which may cause problems if there will be an operating system update which includes libmeegotouchcore0.

    After installation the orientation of all libmeegotouch applications will be unlocked (after they are restarted). Orientations of specific windows can be locked by setting their names to the /meegotouch/orientationlock/names GConf key as follows:

    gconftool -s -t list --list-type=string /meegotouch/orientationlock/names "[Screen Lock]"

    Window names can be checked with the xprop utility available in the x11-utils package:

    # xprop WM_NAME
    WM_NAME(STRING) = "Screen Lock"

    Window classes can also be used by setting the classes of the windows to be orientation locked to the /meegotouch/orientationlock/classes key:

    gconftool -s -t list --list-type=string /meegotouch/orientationlock/classes "[calc,clock]"

    Window classes can also be checked with the xprop utility available in the x11-utils package:

    # xprop WM_CLASS
    WM_CLASS(STRING) = "calc", "Calc"

    The patch checks whether either the name or the class of the class hint exists in the GConf key value.

    Since many of the stock applications have not been maintained to work in landscape, an additional theme package is provided to add landscape theming for those stock applications that have not been maintained in landscape.

    As always, use at your own risk! There is absolutely no warranty. The author takes no responsibility for problems, loss of data or loss of functionality caused by this patch. Also note that QML applications like Facebook and Twitter do not benefit from this patch.

    Edit | Forward | Quote | Quick Reply | Thanks

    Last edited by Vesuri; 2012-08-14 at 09:47.
    The Following 53 Users Say Thank You to Vesuri For This Useful Post:
    aironeous, ajalkane, arcean, Arie, banong, cddiede, CepiPerez, ck2nb, crazyhg, Dousan, Estel, F2thaK, Faz, Garp, godofwar424, guillermorojaz, Hariainm, hood, HtheB, ibrakalifa, jalyst, jberezhnoy, jd4200, jhwan, koe, Kozzi, ladoga, Loginin, MaddogG, Makeclick, Manatus, MAX9, Mentalist Traceur, MFaroTusino, mrtank, munozferna, myname24, nicodonte, nicolai, Nosph3ratu, OVK, peterleinchen, ranbaxy, Salmi, Schturman, shanttu, smcsa, solstice88, thedead1440, TMavica, topet2k12001, w00t, zlatko

     
    Morpog | # 2 | 2012-07-11, 14:47 | Report

    Sounds like incepting it could do the trick to preserve the com.nokia.maemo origin. Anyone going to try out?

    Edit | Forward | Quote | Quick Reply | Thanks

     
    HtheB | # 3 | 2012-07-11, 14:59 | Report

    Vesuri, did you already tried out incepting it first?

    Edit | Forward | Quote | Quick Reply | Thanks

     
    Vesuri | # 4 | 2012-07-11, 17:22 | Report

    Originally Posted by HtheB View Post
    Vesuri, did you already tried out incepting it first?
    It works, but that changes the origin to com.nokia.maemo/local which can cause problems if there ever will be an OS upgrade which contains libmeegotouchcore0.

    Edit | Forward | Quote | Quick Reply | Thanks

    Last edited by Vesuri; 2012-07-15 at 17:17.
    The Following User Says Thank You to Vesuri For This Useful Post:
    OVK

     
    Hariainm | # 5 | 2012-07-11, 18:48 | Report

    This is great! Video anyone, please?

    Edit | Forward | Quote | Quick Reply | Thanks

     
    aironeous | # 6 | 2012-07-11, 19:21 | Report

    This is great as the stock apps that won't do landscape are quite annoying.

    Edit | Forward | Quote | Quick Reply | Thanks

     
    godofwar424 | # 7 | 2012-07-11, 19:30 | Report

    Originally Posted by aironeous View Post
    This is great as the stock apps that won't do landscape are quite annoying.
    Facebook and twitter!

    Edit | Forward | Quote | Quick Reply | Thanks

     
    Vesuri | # 8 | 2012-07-11, 20:30 | Report

    Originally Posted by godofwar424 View Post
    Facebook and twitter!
    Unfortunately those are not libmeegotouch applications and will not benefit from this patch. Sorry.

    Edit | Forward | Quote | Quick Reply | Thanks
    The Following User Says Thank You to Vesuri For This Useful Post:
    godofwar424

     
    Vesuri | # 9 | 2012-07-11, 20:36 | Report

    I'm also working on a theme package which adds landscape theming for those stock applications that have not been maintained in landscape.

    Originally Posted by Hariainm View Post
    This is great! Video anyone, please?
    No video, but here's a screenshot of Phone running in landscape with the theme package installed. The layout is not perfect but at least it's usable:



    Also, here's the Calculator in landscape:



    Clock:



    Music:



    Settings:



    Store:



    Music Store:



    The patch, the pre-built libmeegotouch, the theme package and more information can be found from http://vesuri.jormas.com/harmattan/libmeegotouch.html.

    Edit | Forward | Quote | Quick Reply | Thanks

    Last edited by Vesuri; 2012-07-15 at 18:31.
    The Following 15 Users Say Thank You to Vesuri For This Useful Post:
    arcean, baem90, Bundyo, Dousan, Faz, godofwar424, Hariainm, ibrakalifa, MaddogG, Manatus, MFaroTusino, N9owner, Nosph3ratu, OVK, slarti

     
    eennbb | # 10 | 2012-07-13, 06:54 | Report

    in pr1.3?????

    Edit | Forward | Quote | Quick Reply | Thanks

     
    Page 1 of 7 | 1   2     3   | Next | Last
vBulletin® Version 3.8.8
Normal Logout