Available for a limited time only - £10 off a £20 spend at eXpansys! For more details visit this topic!

Please Log In or Register - it's FREE!

 
Reply to this topicStart new topic
 Can someone make a mortscript to disable auto-rotate, Or show me how?
3shirts
post Sep 30 2008, 10:02
Post #1


Regular
Group Icon

Group: Posters
Posts: 110
Joined: 10th September 2008
Member No.: 424,939

Device(s): Samsung i900 Omnia



I want a simple script that disables auto-rotate, runs a game then re-enables when you close the game.
Can someone do it for me or show me how, I'm not familiar with MortScript scripting
Go to the top of the page
 
+Quote Post
Juicey
post Sep 30 2008, 10:39
Post #2


Newbie
Group Icon

Group: Posters
Posts: 37
Joined: 13th September 2008
Member No.: 425,954

Device(s): Samsung Omnia



Not to difficult.. should be along the lines of this:

CODE
# Disable auto orientation
regWriteDword HKCU,"ControlPanel\MotionSensor","AutoOrientation",0

# Run program and wait for it to finish
RunWait("\Full\path\to\program.exe")

# Enable auto orientation
regWriteDword HKCU,"ControlPanel\MotionSensor","AutoOrientation",1


Change the path to the program you want to run, and save these lines as a .mscr file.

The Omnia will lock to the orientation it's in at the moment of script execution.


This post has been edited by Juicey: Sep 30 2008, 10:43
Go to the top of the page
 
+Quote Post
3shirts
post Sep 30 2008, 10:55
Post #3


Regular
Group Icon

Group: Posters
Posts: 110
Joined: 10th September 2008
Member No.: 424,939

Device(s): Samsung i900 Omnia



QUOTE(Juicey @ Sep 30 2008, 10:39) *
Not to difficult.. should be along the lines of this:

CODE
# Disable auto orientation
regWriteDword HKCU,"ControlPanel\MotionSensor","AutoOrientation",0

# Run program and wait for it to finish
RunWait("\Full\path\to\program.exe")

# Enable auto orientation
regWriteDword HKCU,"ControlPanel\MotionSensor","AutoOrientation",1


Change the path to the program you want to run, and save these lines as a .mscr file.

The Omnia will lock to the orientation it's in at the moment of script execution.


Perfect! That works like a charm, you sir, are a legend
Go to the top of the page
 
+Quote Post
Juicey
post Sep 30 2008, 11:03
Post #4


Newbie
Group Icon

Group: Posters
Posts: 37
Joined: 13th September 2008
Member No.: 425,954

Device(s): Samsung Omnia



QUOTE(3shirts @ Sep 30 2008, 11:55) *
Perfect! That works like a charm, you sir, are a legend


And you Sir, are welcome wink.gif
Go to the top of the page
 
+Quote Post
new2city
post Sep 30 2008, 11:49
Post #5


Regular
Group Icon

Group: Posters
Posts: 119
Joined: 14th August 2007
From: Malaysia
Member No.: 289,073

Device(s): Omnia 8Gb with 8GB SDHC



Great, can use it work on TCPMP as well... double thanks to you too
Go to the top of the page
 
+Quote Post
3shirts
post Sep 30 2008, 13:55
Post #6


Regular
Group Icon

Group: Posters
Posts: 110
Joined: 10th September 2008
Member No.: 424,939

Device(s): Samsung i900 Omnia



Would you happen to know the code I need to change the mouse behaviour too? So I can switch it to mouse mode and back?
Go to the top of the page
 
+Quote Post
Michael122w
post Sep 30 2008, 14:54
Post #7


Regular
Group Icon

Group: Posters
Posts: 67
Joined: 15th August 2007
From: Canberra
Member No.: 289,265

Device(s): Gigabyte i3oo , Samsung Omnia



QUOTE(Juicey @ Sep 30 2008, 10:39) *
Not to difficult.. should be along the lines of this:

CODE
# Disable auto orientation
regWriteDword HKCU,"ControlPanel\MotionSensor","AutoOrientation",0

# Run program and wait for it to finish
RunWait("\Full\path\to\program.exe")

# Enable auto orientation
regWriteDword HKCU,"ControlPanel\MotionSensor","AutoOrientation",1


Change the path to the program you want to run, and save these lines as a .mscr file.

The Omnia will lock to the orientation it's in at the moment of script execution.


Thanks Juicey. Its nice to have some control over the rotation.

I wonder if Samsung is planning to include a program to control which software the auto rotation works on. I saw something like this released for the diamond the other day - it woulld make the device so much more usable.
Go to the top of the page
 
+Quote Post

Reply to this topicStart new topic

Collapse

Similar Topics

  Topic Replies Topic Starter Views Last Action
No new Topic has attachmentsStep by Step: Learn To Cook Custom ROM
guide to cooking your own ROM
81 PaSSoA 8,782 Today, 10:06
Last post by: bmarko82
No New Posts To everyone who cant recharge via USB
2 Jokes On You 185 Today, 13:26
Last post by: deadphill
No New Posts What's the best way to read Japanese on the Omnia?
And also run some Japanese applications, such as EBPocket
0 Kurvenal 12 Today, 10:12
Last post by: Kurvenal
No New Posts Flash from ZHHJ2 to DXHJ1 hung
0 tux1 25 Today, 10:42
Last post by: tux1
No New Posts Automatic correction/xt9 stop to work
0 LGDP 32 Today, 10:59
Last post by: LGDP
No New Posts T*Omnia coming to US?
0 whatledog 48 Today, 12:21
Last post by: whatledog

1 User(s) are reading this topic (1 Guests and 0 Anonymous Users)
0 Members:

 


RSS hit counter Lo-Fi Version Time is now: 23rd November 2008 - 15:37

Please visit our 'Plus Partners' - these companies support MoDaCo through 'MoDaCo Plus' - Click Here for more details!

ActiveKitten | Aiko Solutions | Ateksoft | Binaryfish | Conduits | DeveloperOne | eSoft Interactive | FTouchSL | Inesoft | Lingvosoft |

monocube | Mykesoft | OmegaOne | Omnisoft | Opera Software | Resco | SBSH | Slipstream Solutions | SPB Software House |

Splashdata | Sprite Software | Syncdata | Teksoft | VITO | WebIS | z4soft

Would your company like to become a 'Plus Partner'? Click Here to contact us!