[Info Smartphone] Extend Settings via registry - Windows Mobile Development and Hacking General

This is for Smartphone (Windows Mobile Standard) only - Settings are handled differently on touchscreen (WM professional) devices.
You may have noticed that Windows Mobile Standard had introduced a method of manipulating the Settings application via registry entries in HKEY_LOCAL_MACHINE\System\SettingsApp\<relevant-panel>.cpl.xml\ from WM6.1 onwards.
You can find examples in the \SYS\SHELL\*.RGU
I have not found any documentation on MSDN regarding that sadly, so let me share some findings that may help you to utilize this feature.
It looks all straight forward, you can (ADD, DELETE) at (TOP, BOTTOM) of the panel and the relevant entries are just string values named "0", "1" each carrying the string to extend the panel with (mind to escape all embedded " with \").
To avoid duplicate entries in existing panels there is an (initially invisible) check implemented when a panel is first called - and this is where my investigation ended finally
So when you first call any of the settings panels after cold-boot, the settings function checks the loaded panel with the strings defined in the relevant part of the registry and acts accordingly (ADD, DELETE at TOP, BOTTOM) for display.
It does a second job however additionally: it cleans up the entries that are duplicate (so they exist already in the current panel) and deletes these from the registry.
Sadly this detection logic is very simple and does not ignore the XML comment of the original panel, which is treated properly when displaying the panel. I believe it only takes the added string and checks to find this in the raw panel data (normalizing on blanks, CR/LF and TABs maybe).
How I found the problem:
Motivation:
I wanted to better modularize my kitchen settings and bundle the parts that a package needs to have with that package. So the registry in the .rgu, let the .provxml care about the language settings in MetaDB and now also the relevant dedicated settings panel. So if the build has that package included - then the settings panel is there, if the build was made without that package, then the panel would not be there (and not visible from its parent panel).
Implementation:
When moving the functionality from the dedicated panel to the registry entries, I had decided to just "comment out" the related settings in the original panel and have them added via registry later again.
Problem:
The check for duplication on first call of the relevant settings panel has however removed the registry settings again due to falsely identifying them as "duplicate" as they were still present in the panel, yet commented out there.
Solution:
Remove the entries from the original panel or alter them so that the duplication check will not delete the registry entries.
It took me some time (and wild speculations on why the registry data would not be treated or deleted again) to track that down, so I hope someone may benefit from writing. I know that most will simply delete all the registry extensions and hard-code the panels - but for the sake of modularity there is one trap less to step into.
There are still a few smartphone cooks out there - greetings to all of you!

some more
wrong post selected for reply

Related

Reg Tweak FILES: Post/Get them here

Let's start a thread of all the reg tweaks ppl have come up with. If they are saved as .reg files (to an SD), we can install them with a mere double-click by using TRE (options>associate), and anyone can contribute to this post WITHOUT having to build .cab files! Why is this kewl; cos when u hard reset it's a real ball-ache to go back into all the forums to find the tweaks u applied and to navigate thro TRE to re-apply them all. This applies particuarly to settings (Owner info etc). Over and above, we are no longer beholden to tweak shareware, but have full and instant control over our settings.
Each tweak should have 2 reg files; Apply the tweak, and remove the tweak (if possible). In this manner, we can have a directory of reg files, and can turn on and off tweaks with a simple d.click.
Attached is a basic set I've compiled. Please let everyone know if any are a problem (ie perhaps whole key gets replaced and overrides something u have already changed). Files described below:
[*]Reg Date_In_Titlebar ON.reg
Adds the date to the title bar, with format according to your short-date format under settiings>regional (or found manually changed in another Tweak I'll cover later). I do NOT have a .reg file that will undo (ie delete) this new key, but it's easy to see what key is being added so u can delete it. <Credit: Well known PPC tweak - I probably learnt from toenailed>
Can someone please find out where we can change the font for this - it's a horrible bold font that doesn't fit in the space available?
[*]Reg Font_Menu_+_Pop_700 ON.reg
Change menus and popups to a smaller font. Nice size, makes VGA look more VGA-like, yet not so small that it fails cleartype nor looks daft. Requires a reset. <Credit: Well known PPC tweak - I probably learnt from toenailed>
[*]Reg Font_Menu_+_Pop_900 DEFAULT.reg
Reset above change to default of 900
[*]Reg Font_System_700 ON.reg
Changes system font to 2 pts smaller. I find that dialog boxes with radio buttons got a bit wierd, and you don;t get much more screen estate height cos of icon sizes staying the same in file lists, so I don't bother with this tweak. Requires a reset. <Credit: Well known PPC tweak - I probably learnt from toenailed>
[*]Reg Font_System_900 DEFAULT.reg
Turn above off
[*]Reg GPRS_+_3G_Always _On DEFAULT.reg
Awesome tweak to make sure ur phone connects to GPRS/3G and stays there. However, you'll want to switch this off overnight etc, which is the main reason I created this post and these reg files. NOTE: you will absolutely HAVE to replace the "MTN SA Web" bit with the name of your connection which you will find in this key using TRE
<Credit: BrettS http://forum.xda-developers.com/viewtopic.php?t=30277>
[*]Reg GPRS_+_3G_Always _On ON.reg
Turn off the above. Remember to change connection name in file
[*]Reg PIE_Homepage_Default.reg
When u press the E (explorer) keyboard key u go to clubimate homepage - annoying. This resets that hard button to whatever u want (current reg file is windows\default.htm)
<Credit: I forget, someone on clubimate forums>
[*]Reg TerminalServices_Cache_Larger DEFAULT.reg
AWESOME improvement in Terminal Services client horrible black blocks. Increases cache sizez - I did not notice an increase in traffic/cost
<Credit: Carnivor from MS KB http://forum.xda-developers.com/viewtopic.php?t=29996>
[*]Reg TerminalServices_Cache_Larger ON.reg
Turns above off
More coming as I go thro the wiki and toenailed tweak posts and extract usefull ones for us lonely Universal users...
can you add the actual keys to here?
http://wiki.xda-developers.com/index.php?pagename=Universal_Registry
cos of this thread
http://forum.xda-developers.com/viewtopic.php?t=30396
Doh! That post came up after I started this thread.
Still this thread is useful for the actual .reg files to same n00bies some time (and to save me time too). I'll make sure everything here is duplicated there tho.
Here are a few more .reg files:
Several versions of date_in_title_bar (covered above)
Hide_Screen_Rotation icon
Hide that icon that allows u to rotate screen - but JJ does it automatically so Icon is not so necessary
Regional_settings
These are for me - u should edit file in text editor to customise 4 yourself. Best part is my short date format that keeps date in title bar small and visible
Ringtone_settings
Customise as above
Screen_Speed_Glyph_Cache
Double your screen cache. COsts a LITTLE memory, and improves screen size
Screen_font_'smaller'
Set screen font size to "smaller". This can be changed in "settings"m and I only include it here in line with my suggestion that we have a collection of files to run quickly on reset. You may want to customise as above
SIP_Settings. Ditto
All in updated zip file.
I would really appreciate if anyone can find a way to get rid of the Last Call in the dialer screen... I know its somewhere hidden in Registry, but I dont seems to be finding a way to get tru it...
Having the Last Dialed No. showing rite up on the Dialer Screen is really bothering and if you happened to press the phone button by mistake twice there we go the last dialed no. has been dialed already for you....
Bump: no-one contributing to this learning?
haven't found anything else worth posting yet m8, u got the best ones already :wink:
craigiecraigie4: Thanks for these - great idea!
I have a suggestion:
HKCU/ControlPanel/Backlight sets the backlight duration for the keyboard (in seconds). It's available through the control panel, but I like it set to more than the CP maximum of 10 seconds. Sorry - I don't know how to create a reg file.
To reset, choose another value in the backlight control panel applet.
Don't have any others to add though
Found another one:
Change the width of the vertical scroll bar and the height of the horizontal scroll bar so they take less room on the screen:
HKLM\System\GWE
Change cxVScr to (say) 10 to make vertical scrollbar narrower. Default value is 14
Change cyHScr to (say) 10 to make horizontal scrollbar narrower. Default value is 14
This change affects various scroll options in the system including the up/down arrows in selection boxes. 10 is a nice size.
This one is in this forum:
from davidberrysmith
--------------------------------------------------------------------------------
Any body remember these reg tweaks from himalaya? they still work
*** Speed Up Your Windows Mobile Pocket PC.
1. Open your registry editor o_n your Pocket PC
2. Navigate to HKEY_LOCAL_MACHINE\SYSTEM\GDI\GLYPHCACHE\
3. Change the value of 'limit' from 8192 to 32768
4. Close registry editor and soft reset.
*** disable start menu animation
Browse to HKEY_LOCAL_MACHINE\SYSTEM\GWE\Menu\
Change the "AniType" value from 6 to 0.
_________________
i-mate jasjar
Click to expand...
Click to collapse
SiliconS said:
Found another one:
Change the width of the vertical scroll bar and the height of the horizontal scroll bar so they take less room on the screen:
HKLM\System\GWE
Change cxVScr to (say) 10 to make vertical scrollbar narrower. Default value is 14
Change cyHScr to (say) 10 to make horizontal scrollbar narrower. Default value is 14
This change affects various scroll options in the system including the up/down arrows in selection boxes. 10 is a nice size.
Click to expand...
Click to collapse
Nice one dude. I can't make the .reg file cos I can only create reg files of the entire key, and there are too many other things under GWE that users may have changed.
Internet Explorer
Somewhere in those forums I found the IE reg hack to make mine 5.5, this helps connecting to my bank account and viewing other secured sites.
read this somewhere
To change the ability to receive files via Bluetooth (OBEX)
The setting is at 'HKEY_LOCAL_MACHINE\Software\Microsoft\Obex'
The 'IsEnabled' DWORD value should be set to '1' to enable OBEX and '0' to disable OBEX.
For example, to enable the ability to receive fles via Bluetooth
HKEY_LOCAL_MACHINE\Software\Microsoft\Obex\IsEnabled = 1
says receive so i dont know about send, try it!! might be it
But apparently now this is the same feature as the receive incoming beams setting in connections.
Yes, I know that's not free but 90% of all this hacks have been included in Tweaks2K2. And the other 10% are about to be included :twisted:
Yeah, true. Idea of this thread was to have a facility whereby a hard reset can be quickly restored to a working device - install a few basic apps, run the .reg files, and there u go. Takes me about half an hour from HR thro to up and running perfectly.
craigiecraigie4 said:
Yeah, true. Idea of this thread was to have a facility whereby a hard reset can be quickly restored to a working device - install a few basic apps, run the .reg files, and there u go. Takes me about half an hour from HR thro to up and running perfectly.
Click to expand...
Click to collapse
With your .reg files as inspiration I'm just about getting there in the same way. I've written down all the steps and I just run through them. I've done this since I had my XDA2 and it makes a hard reset so much less traumatic:
Code:
Hard reset. Wait for Today screen then soft reset.
Connect cable to ActiveSync. Set up guest connection.
Turn off beams, error reporting
Set basic clock accuracy
Copy Step 1 files to root of PPC [These are the CABs for the programs I install]
Run CABs. Leave O2 Connections CAB. Put gps.CAB and PIMAddin onto storage card
Run TRE registry editor. Associate .reg files to TRE
Open the .reg file [This applies my registry settings. See below]
Run O2 connections CAB
Copy all Step 2 files to root of PPC [This adds shortcuts to StorageCard-installed programs to my Start Menu and gives me my freeware email client and PZP icons and profiles]
Run SDK Certs CAB
Run OzVGA. Change all fonts to same size as qVGA
PPC: edit registry: browse to HKLM\ControlPanel\GPS Settings. Delete the DWORD marked "hide"
CPL > Personal > Buttons: match Button 2 to [Task switcher], Button 4 to <Rotate Screen>; Set button lock
CPL > Personal > Menus: ActiveSync, File Explorer, Internet Explorer, nPOPw, Pocket Informant, Task Manager, TomTom Navigator
CPL > Personal > Owner: set owner information
CPL > Personal > Phone: change band to GSM
CPL > Personal > Today: set items to Date, PZP, PocketPlus, PocketBreeze, Messaging; set theme to Windows Default
CPL > System > Clock: Show time on all screens
CPL > System > Regional: Set locale to UK
CPL > Connections > GPS: set program port COM0
Soft reset
Set password for PPC
PC: backup previously sync'ed files folder
PC ActiveSync: delete previous partnership. Don't delete sync'ed files folder
CPL > System > About: Set DeviceID = XDAExec
Connect PPC and PC with cable
Sync only Contacts, Calendar (all), Tasks, Favourites
Sync files. Replace the items on the device
PocketBreeze: import settings
PocketPlus: import settings
PocketInformant: run and let it fanny about
PocketWeather (on PocketBreeze tab): import settings
Run ListPro. Enter registration code
Disconnect from PC
Set up phone speed dials
Set up voicedial tags
Set up ActiveSync via Bluetooth to Workstation
Set up bond to headset
Set up bond to GPS thingy. Choose Serial Port as profile
Start TomTom Navigator. Run through startup.
InternetExplorer: sort out view settings. Set default page to about:blank
Choose Transcriber input method. Import settings file
This is my .reg file that does almost everything I need done in one step:
Code:
[HKEY_LOCAL_MACHINE\ControlPanel\GPS Settings]
"Group"=dword:00000002
[HKEY_CURRENT_USER\ControlPanel\Backlight]
"QKeyLedTimeout"=dword:0000001e
[HKEY_CURRENT_USER\Software\Microsoft\Terminal Server Client]
"Keyboard Layout"="00000409"
"BitmapPersistCacheSize"=dword:00000001
"BitmapCacheSize"=dword:00000015
[HKEY_LOCAL_MACHINE\System\GDI\GLYPHCACHE]
"limit"=dword:00004000
[HKEY_LOCAL_MACHINE\nls\overrides]
"SSDte"="d/M "
[HKEY_LOCAL_MACHINE\HARDWARE\OEM\KEYBD]
"PieHomePage"="about:blank"
[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Shell]
"TBOpt"=hex:\
13,00,00,00
It makes a massive difference using commercial software that has a reliable import/export process for the settings and this, IMHO, is usually the biggest difference between paid-for software and freeware alternatives.
Silicon, don't u want to re-post your post here:
http://forum.xda-developers.com/viewtopic.php?t=31697
We need more of these 'standard' configs to help new users get up n running without giving up on their universal.
dude, your screen - how?
craigiecraigie4
how did you make htc look like that?
is it standard? emailable? I don't really want the merc style if it can be changed, but its a nice screen all the same
Re: dude, your screen - how?
simon_darley said:
craigiecraigie4
how did you make htc look like that?
is it standard? emailable? I don't really want the merc style if it can be changed, but its a nice screen all the same
Click to expand...
Click to collapse
You don't want merc!! well u can just f off then! ;-)
It's WisbarAdvance2 with WAD - see another post I started in this forum. u can put in on any universal, with whatever walpaper u want, and there are plenty of free skins
Re: dude, your screen - how?
craigiecraigie4 said:
It's WisbarAdvance2 with WAD - see another post I started in this forum. u can put in on any universal, with whatever walpaper u want, and there are plenty of free skins
Click to expand...
Click to collapse
Whatever it is, it's distracting to have such a big picture in your signature in such text-based forums.
Sorry craigiecraigie4. Don't mean to offend. Just MHO.

noob help with Titanium Panel

I'm new to Titanium Panels and can't seem to find the "10,000 foot view" of how these work. I hope to do that here...
I'm now in "build the tutorial mode" so this post will change as I have time to fill it in.
As I see it, Titanium Panels fall into three categories:
Completely Static - A fancy button to launch an application.
Update on Demand - Static until you tap it and then it updates.
Automatically Updated - This model has a "free-running" background process that updates the panel contents on a regular basis.
The general model is something like this...
Create an app/script/etc. that puts data into the registry (when/if necessary.)
These values should be listed in subkeys in the registry under:
Software\Microsoft\CHome\PanelName\CondensedPage
Software\Microsoft\CHome\PanelName\Page1
Software\Microsoft\CHome\PanelName\Page2
etc.
to form what data will actually appear on each page.
There are special values in the registry that specify the Datasource, Tap actions, etc.
Create a resolution specific layout in the Titanium.cpr file.
When necessary, update the registry values and toggle a special registry entry:
Software\Microsoft\CHome\PanelName\Updated
to 0 and then back to 1. (Some languages (like c#) require that you flush() your changes in order for this to work.)
Also see the post later in this thread "Updating Panel".
Then Titanium renders the data items on the current page for this panel (CondensedPage and/or some Page1 ... PageN) using the layout items in the .cpr file.
I have the same problem - I don't know how to refresh a single page. Refreshing the entire HS by its GUID works, but the same trick won't work on a single page. Refreshing it by the panel GUID also don't work...
Updating Panel
Simply toggle the "Updated" registry key to 0 and then back to 1.
Sample c#:
Code:
rk = Registry.LocalMachine.OpenSubKey(@"Software\Microsoft\CHome\" + PanelName, true);
rk.SetValue("Updated", 0);
rk.Flush();
// update all of the data for this panel...
rk.SetValue("Updated", 1);
rk.Flush();
In any language the idea is the same. Originally I was having trouble when I was simply setting Update to 1 without toggling it.
Hope that solves it for you.
BTW - I have no idea how to refresh a single page of a single panel or if that's even possible.
So I wrote a simple updater:
Code:
RegistryKey klucz = Registry.LocalMachine.OpenSubKey("Software\\Microsoft\\CHome\\SlidingAlbums", true);
klucz.SetValue("Updated", args[0], RegistryValueKind.DWord);
klucz.Flush();
I'm running it by Pocket Controller-Pro from the command line, and no respond.
So... I guess that you are calling it with a "0". Then changing some registry value. Then calling it again with a "1". And the data on the screen isn't changing?
This update only changes the data displayed, it does not cause a "reload" of the .cpr file.
How are you changing the registry values that relate to the data used by the panel? What is the "whole" picture here?
Also note that the panel name is case sensitive.
rakar said:
So... I guess that you are calling it with a "0". Then changing some registry value. Then calling it again with a "1". And the data on the screen isn't changing?
Click to expand...
Click to collapse
Yes, I've also tried to change it from .NET project but the effect is the same.
rakar said:
This update only changes the data displayed, it does not cause a "reload" of the .cpr file.
Click to expand...
Click to collapse
I know, I wanna refresh the data from registry.
rakar said:
How are you changing the registry values that relate to the data used by the panel? What is the "whole" picture here?
Click to expand...
Click to collapse
I'm changing TEXT1, TEXT2, TITLETEXT.
rakar said:
Also note that the panel name is case sensitive.
Click to expand...
Click to collapse
I know that
But there's one thing - I'm doing it on WM6.1 Standard. Maybe this is the main problem, but I think that CHome is working the same as it is on 6.5 Professional.

[APP] Control Panel Settings to Links (.lnk)

Hi guys,
I know it's a 10 seconds job to create a link for items inside the control panel (settings) such as "Usb to PC" or "Power" but I'm too lazy to do it every time I try a new rom,
also I found some of the values change from rom to rom, so I create a really simple app that goes through the registry key which holds the settings items (KLM\Security\Shell\StartInfo\Start) and creates a .lnk file for each of these entries.
Having a direct link allows me to add that option as a quick link which is handy 8)
Anyway, here is the tool in case someone wants it.
The exe must be installed in "\Program Files\CplLinks" (Device). It only takes 11.5 kb. The only reason the .exe is needed after the lnk are created is to provide an icon.
When you run it, it reads the HKEY mention above and creates .lnk for each item in the "Settings" menu. The lnks are created in "\Windows\Start Menu\Programs\CplLinks" so are directly accessible through the Programs menu.
There are no messages, it runs and creates the links, no interaction whatsoever so do not expect any nice popup window 8)
Next version will use specific icons for each item, right now, all the links use the same icon from the cpllink.exe executable.
The icons for most of the Settings are .png files rather than .ico, and WM doesn't have an easy way to convert from .png into .ico, the idea for a "future version" is to collect all the .png files,converted to icons and create a dll on the fly with the icons as resources, so they can be referenced from the .lnk files
Couple of screen shots from the emulator.
Great application! It works like a charm! Thank you for this convenient time saver
EDiT (another time saver)
After applying a Hard Reset WE have to reinstall all programs if you have previously installed them in the memory card. Often it is sufficient to recreate the shortcut in the start menu. ShortCutCreator helps you to recover the exe files and to recreate the desired shortcut.
Thanks for sharing!
I guess would be better if I manage to provide a different icon for each link, but Icon support is quite limited inside VM. Need to work in the PNG to Icon -> .dll routine 8)
I though having the app in internal memory was a better solution than in \Storage Card, so it will take less time to load the icon from the program, but I can change it and allow that option, so the icons in the links are pointing to \Storage.. rather than \Programs..
Anyway, it just a time-saver thingy 8)
Nice app. It does not seem to work on WM6.1 though.
It does create a new folder structure: CplLinks\System inside the Start Menu.
Very nice. It does seems to create a bunch of redundant or non-used links though
Yep, I saw it only works on WM6.5, on WM6.1 there are no "StartInfo\Start" in the "KLM\Security\Shell\". Not sure where it keeps that info, maybe somewhere else in the registry.
I finally managed to convert PNG to ICO, so I think next version would allow you to choose which items you want to create links for rather than just dump everything 8)
dubidu said:
Yep, I saw it only works on WM6.5, on WM6.1 there are no "StartInfo\Start" in the "KLM\Security\Shell\". Not sure where it keeps that info, maybe somewhere else in the registry.
I finally managed to convert PNG to ICO, so I think next version would allow you to choose which items you want to create links for rather than just dump everything 8)
Click to expand...
Click to collapse
WM6.1 control panel is "HKLM\ControlPanel" if I remember correctly. There will be numbers for the mycpl stuff and words for some other control panel items like backlight, etc.
I think this post got lost in the last database disaster 8)
I wrote a new version of this tool that now gives you the icons for the control panel settings, check it out here:
http://forum.xda-developers.com/showthread.php?t=791682

[TUT]Baby steps with ceregeditor - comparing for registry changes

A brief 'how to' about finding which registry keys control simple settings.
(There are other methods and software, but the principal of save file, make changes, compare to file is common throughout)
HKCR - Hot Key Classes Root - not really sure, never really looked though, i always ignore it.
HKCU - Hot Key Current User - Holds short term info and user settings for the most part. Expect lots of changes found when you search this branch.
HKLM - Hot Key Local machine - Generally hard system settings, pretty static.
Get 'ceregeditor' and install it,
connect the phone to usb and allow it to connect to activesync,
in ceregeditor click connection - connect, jump to tools - unlock registry
(skip this step unless you get an error pops up later saying you cant make changes)
Now, down the left you see your registry main keys in a standard tree layout, HKCR, HKCU, HKLM
and on the right, the keys and values within the selected branch when you select on the left.
So, you want to find out which registry key controls, for example, phone keypad tones, long, short, off.
Select HKCU on the left, right click and choose export - and save it as something, HKCU would be the obvious choice, it doesn't matter.
Do the same for HKLM.
It will save all the sub keys of wehatever you select on the left.
you can select to start from sub keys by selecting the appropriate key in the left column, assuming you know which part of the registry you want to search.
most hardware settings are held in HKLM, with things like user preffs found in HKCU, but be warned HKCU changes frequently, so expect a long list of changes when you run a registry compare.)
Once you have saved the files (in all honesty, i dont create them both, usually i check HKLM first, and if i dont find what im looking for only then do i check HKCU)
make your change on your phone
(set phonepad keytones to off, for instance) then back in ceregeditor, right click the selected registry key and choose reload selected.
This makes sure ceregeditor is now aware of the new registry value from the phone.
Now go to compare - compare registry.
It will ask you for a file, point it to the one you just saved, and let it run, , ,it will tell you what keys have changed.
You may occasionally get unconnected changes thrown up, but use a little common sense and you can usually tell what is usefull and what isnt.
In the results window, down the left are the items that have changed, with details of the change on the right.
In our example with the keytones, (not a great example since the target is in the HKCU and so is lost among lots of other changes) you should be able to figure out that the keytone settings are held in
HKEY_CURRENT_USER\ControlPanel\Sounds\Keypress beepmode
Its usually fairly obvious which is the key you are after amid the noise of random system state changes.
When you find your target, put a tick in the box and hit export. You can now save that key (or keys if there are several changes you want to save)
Save it as .cereg and you will be able to simply run that file on your phone to apply those settings.
Or, with wincecabmanager (my other recommended piece of software alongside ceregeditor) its easy to import the reg file into a cab. You can keep adding to that cab as you find and extract more personalised settings.
Keep it in your autoinstall folder on your sd card, and it will always be applied when you hard reset.
My own 'my tweaks.cab' file is fat with various settings, tweaks, etc and i still add to it regularly.
It's true that it's often easier to trawl <searchengine></searchengine> and find the answer, and maybe even a cab to turn it on and off, but its a nice way to start p0king at your registry and seeing how things work, plus you can make one cab for yourself, adding tweaks one by one, without remembering to store loads of different ones and re apply them when you restore/hard reset.
you know, i've never thought of exporting the whole hkcu or hklm directory before. i'm going to have to try that. it'll be interesting to read through a lot of that.
I too have a registry tweak CAB for both my Wizard & Rhodium. Haven't made one for the HD2 yet, since most of the tweaks I've made were through one of the many different tweaking apps.
also, what's this about an autoinstall folder?
*edit* disregard the last part. I always use official roms so the autoinstall doesn't apply

[APP][14/01/2011] FoddTweak using DynamicMenu - ROM customisation & Menu Tool Kit

Hi there chef's! I'm not sure if any of you will find this useful but I'll post it in case you do...
I designed this little mortscript application so that users of my rom can tweak a few settings to their needs and because all of the other tweak applications couldn't be tweaked easily themselves without learning .NET or something similar.
I wasn't getting much feedback so I thought perhaps it wasn't customisable enough or maybe you didn't like my selection of tweaks. Perhaps you thought the menu layout sucked?
Anyway, to address those problems I've moved this on quite a way. It now includes a set of functions for creating Menu's. To Find out how, see the section titled DynamicMenu.
FoddTweak
Backup and restore of important data (Full registry, Titanium configuration, Start menu cpr files, Start menu icon registry settings)
Icon removal to save RAM (all, or all but settings (HTC icons are excluded))
Titanium plugin injection/removal and plugin order settings
Slide lock settings (both manila and wm6.5)
Enable/Disable Sleuth's myLocation service (soft-reset needed)
Enable/Disable start menu replacements and complete removal of the WM6.5 start menu
FoddTweak depends on a few things:
MortScript! (tested on 4.3.b15)
DynamicMenu (included in versions>0.0.1)
TICS Installer (for plugin injection/removal, included in versions>0.0.1)
FDC task manager (for backup purposes, included in versions>0.0.1)
DynamicMenu
It works like this; the menu system 'compiles' a master menu source file with extension mgs to it's component mgc files for each menu. If you want DynamicMenu to 'recompile' then just delete the top level compiled menu (e.g. If you add new options to "FoddTweak.mgs" then delete "FoddTweak.mgc" then re-run FoddTweak.)
This is a sample file, which is used to create menu's for the FoddTweak application:
Code:
menu(FoddTweak:Main Menu)
item(Toggle Lock on Screen Dim:true:Call:"AnyRegWrite", "Toggle", "HKCU", "ControlPanel\Backlight", "AutoDeviceLockEnable")
item(Sleuth's myLocation Service:true:Call:"AnyRegWrite", "Toggle", "HKLM", "Services\myLocation", "Enabled")
item(:false)
menu(RAM Savings:RAM Saving Options)
item(Remove all Start Menu Icons:false:Call:"RmAllStartIcons")
item(Remove all but Settings Icons:false:Call:"RmAllButSettings")
item(Remove the Start Menu:false:Call:"RmStartMenu")
endmenu
item(:false)
menu(WM6.5 Settings:WM6.5 Specific Settings)
item(Toggle WM6.5 Slide Lock:true:Call:"AnyRegWrite", "Toggle", "HKLM", "Software\Microsoft\Shell\LockScreen", "Enable")
item(:false)
item(Titanium Plugin Injector:false:Call:"TitaniumPluginInjector")
item(Titanium Plugin Uninstaller:false:Call:"TitaniumPluginUninstaller")
item(Titanium Plugin Order:false:Call:"TitaniumPluginOrder")
endmenu
item(:false)
menu(HTC Sense:HTC Sense Options)
item(Toggle Sense 2.5 Slide Lock:true:Call:"AnyRegWrite", "Toggle", "HKCU", "Software\HTC\Manila", "Home.lock.Enabled")
item(Toggle Sense Menu Replacement:true:Call:"ToggleSenseMenuRep", "Toggle")
endmenu
item(:false)
menu(Backup:Backup Options)
item(Make Backup:false:Call:"Backup")
item(Select Backup Folder:false:Call:"SelectBackup")
item(:false)
item(Restore ZIP Backup:false:Call:"RestoreZIP", backupdir\"*.zip", "\Windows")
item(Restore REG Backup:false:Call:"RestoreREG", backupdir\"*.reg")
endmenu
endmenu
Syntax
It should be quite obvious how the menu/submenu entries work with a title and description-those can be nested without any problems (though, I only tested one nesting at present.)
Menu syntax is a little restricted, you can't have the colon (":") symbol in the name or description as it's used as a field delimiter and they must be string literals:
Code:
menu(name:description)
...
endmenu
For your menu items, the ItemName and Mortscript Command are string literals. Arguments which are not enclosed in double quotes will be interpreted as variables (I haven't tested this though,) which obviously must be set by the calling script before the call to DynamicMenu().
You can make use of any Mortscript function that the script which calls DynamicMenu() has access to and of course Mortscript commands such as "Run" etc will also work just fine so with this you can access any system command as well.
The testing field for the items is important, if your function supports taking it's first argument as the word "test" and outputting something, that something will be output in brackets next to the menu item. Sounds vague? Well, it is. That something can be anything, true/false, a string. Whatever. So the idea is that it'll be used to denote whether a switch is on/off or the value of that particular menu item...
Code:
item(ItemName:Can it be tested?:Mortscript Command:Argument1, Argument2, ..., ArgumentN)
To put in a seperator you can include a blank line in the menu using the code below. I wouldn't recommend it due to differences in screen size, but if you wanted a dashed line as the seperator, for example, then just fill the first field with hyphens. Seperators are as follows:
Code:
item(:false)
It's a v.simple language, I haven't included any comment support and it's line by line but see what you make of it
Interesting line of thinking. I like the idea of removing the SM icons. I will play with this and see what it can offer. Thanks...
sorry to bump this, but I've updated the menu compiler a little so it shouldn't be thrown off by menus or items which have parentheses in the name or description...
Plus, I added the menu option for the RAM savings again. Hope you like it.
arealityfarbetween said:
sorry to bump this, but I've updated the menu compiler a little so it shouldn't be thrown off by menus or items which have parentheses in the name or description...
Plus, I added the menu option for the RAM savings again. Hope you like it.
Click to expand...
Click to collapse
Very good idea, trying it now
ciao
Removing the reg is almost equivalent to disabling the SM. I do love your concept, and have included this in my personal ROM...
glad you like it that much!
I was hoping that chefs and users alike would get involved writing menu source files so if you think any would like this then point them to here. Tell them that, FoddTweak is the Tweakable Tweak app
I am still trying to get a grasp of the menu source! Havent checked into your latest files yet...but planning on soon...
Thanks a bit late finding this but looks a great tool

Categories

Resources