+ def get_desktop_orientation(self):
+ """
+ Return desktop orientation
+
+ NOTE: This is the desktop orientation as it was introduced in CSSU.
+ Not the device orientation.
+
+ @return "portrait" or "landscape"
+ """
+
+ sw=gdk.screen_width()
+ sh=gdk.screen_height()
+
+ if sw>=sh:
+ ret='landscape'
+ else:
+ ret='portrait'
+
+ return(ret)
+
+ def is_rotating_desktop(self):
+ """
+ Check whether the desktop will change to portrait mode, as
+ added in CSSU.
+
+ @return True/False
+ """
+
+ c=self.gconf
+
+ # This returns False if the key doesn't exist
+ ret=c.get_bool('/apps/osso/hildon-desktop/ui_can_rotate')
+
+ return(ret)
+