[EKEN M001]Modify Volume buttons to scroll - Android Software Development

How to modify Volume buttons to scroll buttons
I managed to remap the volume buttons "+" and "-" on the tablet to scroll buttons.
you need to edit the files english.us.kl and qwerty.kl found in /system/usr/keylayout folder.
Open each of the 2 files and replace:
"key 115 VOLUME_UP" with "key 115 DPAD_UP"
"key 114 VOLUME_DOWN" with "key 114 DPAD_DOWN"
Save the files and restart the tablet! That's it!
Source SlateDroid Forum

Rooted device
Does it need rooting?

So does this work on any scrollable view? What if there are two separate scrollable views on the same page? Which one takes the scroll?
From something awesome

vagonr said:
Does it need rooting?
Click to expand...
Click to collapse
yes, without that you can't modify a system file like this
killersnowman said:
So does this work on any scrollable view? What if there are two separate scrollable views on the same page? Which one takes the scroll?
From something awesome
Click to expand...
Click to collapse
it should work everywhere. the behavior is like the trackball's on Nexus One, and i AFAIK items have focus on Android so the current one will be scrolled

Related

How-to: Program other function to the useless backlight key

From this thread:
http://forum.xda-developers.com/viewtopic.php?p=189058#189058
SiliconS said:
cktlcmd said:
MvanIperen said:
it is mappable
add the following key to the registry:
HKLM\SOFTWARE\Microsoft\Shell\Keys\40C8
and create values just like another key (i.e. 40C5)
soft-reset and then you are able to program the button.
Click to expand...
Click to collapse
Can anyone expand to his instructions please. Did anyone tried to remap their backlight button yet?
Click to expand...
Click to collapse
I just tried and it works. Copy the complete key for 40C5 and call it 40C8. Choose a different name for the button (e.g. 'Button Light').
I guess we could rename all buttons the same way so we could actually have a clue which buttons they were when we were programming them.
Thanks for the tip, MvanIperen
Click to expand...
Click to collapse
Makes me wonder which other key actions we could capture with this registry key. Would all these buttons respond to a press-and-hold? Anybody know how to achieve that?
The key HKLM\SOFTWARE\Microsoft\Shell\Keys\40C4 refers to the press-and-hold action of the notes button, but I can't tell what in the key makes this different behaviour from the press-once action for the same button (key 40C5). Maybe it's just the name of the key. 40C4 is always press-and-hold for that button and 40C5 is press-once. Maybe it's in the hardware this way.
Or does someone know differently? How did MvanIperen know that 40C8 refers to the backlight button? What's at 40C6 and 40C7? 40C9?
Answers below please
Thats an absolutely fantastic find. I wonder if we can actually map individual keys to different functions. Now that would be simply superb!!!
40C1-Contacts
40C2-Video Telephony
40C3-Camera
40C4-Voice Recorder
40C5-Speed Dial
40C6-???
40C7-???
40C8-Backlight (now added)
40C9-???
.
.
.
.
Any suggestions guys?
I have pm'd MvanIperen. Hopefully, he will join us soon. Look forward to his input in this...
UD.
Sorry guys,
I've been trying to map various buttons, and keys but with no result so far.
Will let you know when I find out something new.
Brilliant!
I've mapped the backlight to WA2's new "Toggle Screen" program, and now my backlight button does what I've always thought it should have done in the first place.
Many thanks!
Hey,
Thanks for trying Ivan. We look forward to any input from you. Just one question though, how did you manage to figure this bit out?
Cheers.
universaldoc said:
Hey,
Thanks for trying Ivan. We look forward to any input from you. Just one question though, how did you manage to figure this bit out?
Cheers.
Click to expand...
Click to collapse
I found this by luck, using pocket artist. The backlight key was mappable to an action, and it gave the code C8. The rest was just deducting from registry. Sorry not to have posted this in a proper thread, I was busy at work.
Guess I should have had to get the bell and whistle :wink:
http://forum.xda-developers.com/viewtopic.php?t=33466&postdays=0&postorder=asc&start=0#185747
Can you guys please give me a step by step instruction. I have no idea as to what you guys are taking about. PLEASE.
cktlcmd said:
Can you guys please give me a step by step instruction. I have no idea as to what you guys are taking about. PLEASE.
Click to expand...
Click to collapse
1. install PHM Regedit (or any other registry editor)
2. go down to this location HKLM\SOFTWARE\Microsoft\Shell\Keys
3. create a key "40C8"
4. Go to the key HKLM\Software\Microsoft\Shell\Keys\40C5
5. Select all values under that key and copy it
6. Paste it under the new key "40C8" you just created in step 3
7. rename it to suit a readable name like "Backlight"
8. Softreset using some app like psShutXP or pocket plus (and NOT using the hole)
8. now, you can configure this button as u do normally (for the rest of the buttons)
S
dreamtheater39 said:
8. Softreset using some app like psShutXP or pocket plus (and NOT using the hole)
Click to expand...
Click to collapse
I reset using the hole with no problem at all.
dreamtheater39 said:
1. install PHM Regedit (or any other registry editor)
2. go down to this location HKLM\SOFTWARE\Microsoft\Shell\Keys
3. create a key "40C8"
4. Go to the key HKLM\Software\Microsoft\Shell\Keys\40C5
5. Select all values under that key and copy it
6. Paste it under the new key "40C8" you just created in step 3
7. rename it to suit a readable name like "Backlight"
8. Softreset using some app like psShutXP or pocket plus (and NOT using the hole)
8. now, you can configure this button as u do normally (for the rest of the buttons)
S
Click to expand...
Click to collapse
THANKS VERY MUCH TO YOU AND EVERYONE WHO POSTED. I GOT IT WORKING. YAHOOOOOOO!
Basically, I now get the idea of how to assign these. Thus, we can also assign "press and hold" functions to button 1, 2, and 3, by simply copying the files off 40C4 and renaming "button 4" to either 1, 2, or 3, depending which button we want the "press and hold" function.
Now if only we can reassign "press and hold" functions to any key. That would be something really to celebrate.
universaldoc said:
40C1-Contacts
40C2-Video Telephony
40C3-Camera
40C4-Voice Recorder
40C5-Speed Dial
40C6-???
40C7-???
40C8-Backlight (now added)
40C9-???
Any suggestions guys?
Click to expand...
Click to collapse
40C6- Volume up
40C7- Volume down
Thank you all guys, I remmaped the Light Button to be the OK/Close button of programs and works great!
I'll try now the sliders (uo/down) volume.
@Azhad,
Thanks!!!
40C1-Contacts
40C2-Video Telephony
40C3-Camera
40C4-Voice Recorder
40C5-Speed Dial
40C6-Volume Up
40C7-Volume Down
40C8-Backlight (now added)
40C9-???
.
.
.
.
40C9 - Calendar
DaveUK said:
40C9 - Calendar
Click to expand...
Click to collapse
Which is the calendar button?
Left side next 2 green phone key. Also programs the screen calendar button to the bottom left of screen.

Copy/paste under hardware key?

I am using the smartkey program to hold the softkeys to enter startscreen.
Now I am looking for an option or a program to copy/paste and to put it under the message button.
Or does anybody knows a program that only gives the option to cut/copy/paste.
With this my phone would be perfectly tunned.
aage said:
I am using the smartkey program to hold the softkeys to enter startscreen.
Now I am looking for an option or a program to copy/paste and to put it under the message button.
Or does anybody knows a program that only gives the option to cut/copy/paste.
With this my phone would be perfectly tunned.
Click to expand...
Click to collapse
If the context menu of the program contains copy and paste, you can hold the center key of the 5-ways navigator to popup the context menu.
water
Hi Water,
Thanks, but not all programs have that option. That's why I like to have a program like that.
Right now i'm using Magicbutton but that doesn't have that function. GSMagic had it but I like Magicbutton better. So now I need the copy/past function.
You can try Xbar which is under the D-Pad. It opens up a screen in which you can select the running task but also shortcuts to programs of your liking and there are shortcuts ready for copy and paste and cut.
Wouter
You can use PQz to map a hardware key (I use the Windows-key) to CTRL, so that you can use ctrl-c, ctrl-v etc.
http://forum.xda-developers.com/viewtopic.php?t=33343&highlight=ctrl
I think... just speculating here.. that they are more looking for...
press button - it copies whatever is the active selection
press button again - it pastes whatever is on the clipboard
Not sure, though... ctrl+c / ctrl+v works with the SIP, with that tool it works with the hardware keyboard, and if you're working with the sip - and thus a stylus - you can often just tap-and-hold and choose copy from the context menu.
PHM Keys comes with cut copy paste.
Use a button mapper to do as ZeBoxx says, if it's what you need, and you'll have quick access to said functions.
V
Thanks,
I'm using PQZ now. With TAB as CTRL. WIN would not work together with smartkey, because hold button 1 is the same hex number as WIN.
But this program is realy good.
My Solution to this...
I have a slightly hacked up copy of PHM Keys (couldn't get it to install on my 8125, so I hacked it off of a WM2003 device) that I'm using to solve this problem.
In my Start Menu I have three icons - "Object Copy", "Object Cut", and "Object Paste" (PHM Keys) so whenever I have something highlighted I click my (smartskey modified) Start Menu soft button, scroll down a slot or three with the 5-way, and select the copy/cut/paste operation I need.
When the KB is open it's even quicker Start-o Start-b Start-j respectively. Another plus is this works in nearly EVERY situation where you can highlight something. Sometimes the other options (context menus, SIP kbds, etc.) don't work everywhere.
Now some may not want to waste three Start Menu slots, but I have Tray launch filled with my apps, still have 4 Start Menu slots available, and all my non-soft buttons are mapped to one app or another, so I'm cool with them.
Plus I have my SIP pop-up KB completely disabled (I hate it's "intrusiveness" and only use the HW KB in landscape mode) so in portrait mode I had *NO* way to copy/cut/paste and had to devise something.
Good Luck
-JMS
I've updated VJKeyPress to add -cut, -copy, -paste.
On my website.
V

how 2 associate power button 2 any app

as title says ..........i want 2 associate power btn to pocket suspend is it possible with vj keypress if tell how 2 congigure and if not an alternate will be helpful
I don't think this would be possible. Imagine: Your device automatically turns off (like configured in the energy settings). Now you want to turn it on, but your power button is assigned to another function - device won't turn on. In my opinion, you can't reassign it because it doesn't make sense.
max414: the VJKeyPress page says on the first page:
Some interesting keys:
223 Power Off
27 Escape
91 Start Menu
93 Context Menu
112 Left Soft Key
113 Right Soft Key
Click to expand...
Click to collapse
So 223 is used to simulate PowerOff.
It is possible, but not wise, to override the Power button functionality at a keyboard driver level. But as indicated, you'll never be able to switch it back on again.
FYI VJEschaton has a proper power off mode, not just suspend. Check the thread on this forum.
V
vijay555 said:
max414: the VJKeyPress page says on the first page:
Some interesting keys:
223 Power Off
27 Escape
91 Start Menu
93 Context Menu
112 Left Soft Key
113 Right Soft Key
Click to expand...
Click to collapse
So 223 is used to simulate PowerOff.
It is possible, but not wise, to override the Power button functionality at a keyboard driver level. But as indicated, you'll never be able to switch it back on again.
FYI VJEschaton has a proper power off mode, not just suspend. Check the thread on this forum.
thx i have shortcut of pocket suspend in start...what should ido next..........i clicked on properties of .lnk shortcut with resco explorer and added 223 with space after commas and it didnt work can u tell how 2 do this.....plz
V
Click to expand...
Click to collapse
vijay555 said:
max414: the VJKeyPress page says on the first page:
Some interesting keys:
223 Power Off
27 Escape
91 Start Menu
93 Context Menu
112 Left Soft Key
113 Right Soft Key
Click to expand...
Click to collapse
So 223 is used to simulate PowerOff.
It is possible, but not wise, to override the Power button functionality at a keyboard driver level. But as indicated, you'll never be able to switch it back on again.
FYI VJEschaton has a proper power off mode, not just suspend. Check the thread on this forum.
V[/quote
lpz tell in detail i coudlnt understand on ur webpage and how 2 have fullscreen i dont km=now how 2 use tsc
Click to expand...
Click to collapse
vijay555 said:
max414: the VJKeyPress page says on the first page:
Some interesting keys:
223 Power Off
27 Escape
91 Start Menu
93 Context Menu
112 Left Soft Key
113 Right Soft Key
Click to expand...
Click to collapse
So 223 is used to simulate PowerOff.
It is possible, but not wise, to override the Power button functionality at a keyboard driver level. But as indicated, you'll never be able to switch it back on again.
FYI VJEschaton has a proper power off mode, not just suspend. Check the thread on this forum.
V
Click to expand...
Click to collapse
max414: you just need to edit the exampel shortcuts that come with VJKeyPress and put 223 on the end.
Check out this post on my forum for similar examples with VJTrayLaunch
http://www.vijay555.com/forum/index.php?topic=19.msg19#msg19
VJFullscreenTSC: just setup Terminal Services on your phone, and get it working. Then run VJFullscreenTSC and click the dots and enable fullscreen mode.
V
vijay555 said:
max414: you just need to edit the exampel shortcuts that come with VJKeyPress and put 223 on the end.
Check out this post on my forum for similar examples with VJTrayLaunch
http://www.vijay555.com/forum/index.php?topic=19.msg19#msg19
VJFullscreenTSC: just setup Terminal Services on your phone, and get it working. Then run VJFullscreenTSC and click the dots and enable fullscreen mode.
V
Click to expand...
Click to collapse
ok let me admit something i am a noooob......ok i want that preesin power button will launch pocketsuspend.....which will suspend device in a cool way..ok and i have a shortcut of it in startmenu now i have installed vjkeypress but i dont know what 2 do next......
secondly i dont know how 2 setup terminal services client..ok so i cannt use vj fullscreen...help plz
max414: you have two different questions here. Best to use two threads. Or better still, find the thread on Terminal Services. Don't think about using VJFTSC until you can use normal TS:
http://forum.xda-developers.com/viewtopic.php?p=205704#205704
For VJKeyPress - I don't understand, sounds like you're using PocketSuspend, so VJKeyPress is irrelevant?
In any event, if you've got an app installed in the start menu, you can assign it to hardware keys using the control panel > buttons setting. However, you won't be able to assign anything to the power button. That's not an OS supported function. It'll take some low level hacking to achieve that.
V
vijay555 said:
max414: you have two different questions here. Best to use two threads. Or better still, find the thread on Terminal Services. Don't think about using VJFTSC until you can use normal TS:
http://forum.xda-developers.com/viewtopic.php?p=205704#205704
For VJKeyPress - I don't understand, sounds like you're using PocketSuspend, so VJKeyPress is irrelevant?
In any event, if you've got an app installed in the start menu, you can assign it to hardware keys using the control panel > buttons setting. However, you won't be able to assign anything to the power button. That's not an OS supported function. It'll take some low level hacking to achieve that.
V
Click to expand...
Click to collapse
can u briefly tell what does vjkeypress do ??????
It simulates Key Presses!
Recently I also added clipboard functions, but basic use is to simulate a VK_ key press.
V

[APP] DredSensor v1.1 - Allow you to personalize Hard Key Actions

=======================================================================
New version 1.2 available here
=======================================================================
=======================================================================================
DredSensor v1.1d:
=======================================================================================
Link ->: DredSensor-v1.1d
New features in v1.1d:
=====================
Let you choose which Key/Action you affect to each key.
Launcher Mode let you affect an Action for:
Double Tap event
Click event
Long click event
An icon for config tool is created in Program list.
Cache Program List for quick loading in Config window.
Fixes a few bug from v1.1, v1.1b and v1.1c
Tips:
=====
If you upgrade to this version, your config file will be cleared (sorry ).
To define a profile that applies on every applications, launch config tool and edit "Default" config.
If the key you want to affect is not listed, you can define it manually:
Type "Key:[email protected]@", with @@ = VKey code of the key you want to affect.
You can find VKey code list on : http://msdn.microsoft.com/en-us/library/bb431750.aspx
=======================================================================================
DredSensor v1.0:
=======================================================================================
=======================================================================
Reviewed on gadgetmix.com: See the article
=======================================================================
If you have tried to play a game needing left and right key on an HTC Touch Diamond, you noticed that they are 2mm wide and if you click next to it, you get back to home page or to dialing menu etc...
So I've written a prog allowing you to lock these 4 keys actions and replace it by classical key event (VK_LEFT, VK_RIGHT, ...).
In that way you can play tetris, and use "Pick-Up" and "Hang-Up" keys for going left and right.
Link ->: DredSensor
To use it, you need:
1) An HTC Touch Diamond (it's the only one i have so i can't test it on other models)
2) Install the .cab
3) Reboot your HTC
4) Run a game (or app or ...)
5) Get your stylus out and back-in, in less than 1 second
6) Click "Yes"
----- A config window opens:
7) Check that Type = "HardKeySimul"
8) Click "Ok"
Now you can use (and eventually assign) your 'Home', 'Back', 'Pick-Up' and 'Hang-Up' keys in that game/app.
Actually, the 'Pick-Up' and 'Hang-Up' keys are always defined as Left and Right events.
Have fun.
Ps:
For people interested, the other "Type" in the config window are:
- "Launcher": allow you to quicklaunch 4 app (that you define in the config wnd) when you double tap (not click, just tap) on one of those 4 keyz
- "Scroll": allow you to scroll the current window by tapping those 4 keyz panel
- "KeySimul": allow you to send left/right/up/down events by tapping those 4 keyz panel
Thx, now I can use opera mini and pie (good for mlb's wap) in full screen
Thank you very much. Great program. Now, with left and right softkey hardware buttons, I can play with my java games.
Claus72 said:
Thank you very much. Great program. Now, with left and right softkey hardware buttons, I can play with my java games.
Click to expand...
Click to collapse
Do any of them even work on the vga screen?
first of all: great app!
only thing i don't like is that now every time i pull out the stylus the phone vibrates. maybe you could make the "window-catching-thing" optional, so you have to enable it first?!? with that, the app would be perfect to me!
figured out an other problem: the "scroll-wheel-function" in opera and tomtom doesn't work anymore...
Herr_Knigge said:
first of all: great app!
only thing i don't like is that now every time i pull out the stylus the phone vibrates. maybe you could make the "window-catching-thing" optional, so you have to enable it first?!? with that, the app would be perfect to me!
figured out an other problem: the "scroll-wheel-function" in opera and tomtom doesn't work anymore...
Click to expand...
Click to collapse
Hello.
As it's a background program, making vivrate the phone is the best way i found to easlily know if it's loaded or not.
If you don't like that, you can disable it by manually editing the 'Config.ini' file in '/Program Files/DredSensor':
Go under the section you want to disable vibrator in (ex: "[Default]")
Add: "NoVibrate=1"
For the scroll problem, i didn't change scrolling system from v1.0 so are you sure it was working in v1.0 and it's no more working in v1.1?
@Dredger97
Thank´s for this wonderful tool!
Greeting
Slide
is there a wa to map home/back to A/B controller buttons? Trying to get it to work with PocketNester Thanks
Thanks
I will tried
Seems to be good. Shall download and try...
Doesn't work for all hard keys
I have the original diamond and it doesn't look like any of the key presses work.
I could really do with replacing volume and Home/Back Buttons. Do these buttons
support Long press too?
bugsykoosh said:
is there a wa to map home/back to A/B controller buttons? Trying to get it to work with PocketNester Thanks
Click to expand...
Click to collapse
If you go in PocketNester -> Option -> Controller, you can see that it's default mapped to 0xC4 and 0xC3 key codes.
So all you have to set in DredSensor is:
- Home: "Key:0xC4"
- Back: "Key:0xC3"
I tried that on super mario, it works, but the problem is that you can't press those keys and simultaneously press Left and Right so it's quite hard to play...
In fact you can map Volume Up and Down keyz to button A and B and it's much easier to play.
djfuego said:
I have the original diamond and it doesn't look like any of the key presses work.
I could really do with replacing volume and Home/Back Buttons. Do these buttons
support Long press too?
Click to expand...
Click to collapse
The actual version of DredSensor doesn't change anything to volume up/down buttons.
All it catches is Home,Back,Talk and End hard keys.
About long press,
- In "Launcher" mode, you can define action for "Long click"
- In "HardKeySimul" mode, if you make a long press to "Home", and mapped "Left" key to "Home" button, it will occure a long press on "Left" key.
I just don't seem to be able to get this to work - I follow the first post to remap the home and back keys to the softkeys, but home always takes me back to touchflo.
Are there any other things I can try, or is it just the ROM i'm using doing this?
Furbious said:
I just don't seem to be able to get this to work - I follow the first post to remap the home and back keys to the softkeys, but home always takes me back to touchflo.
Are there any other things I can try, or is it just the ROM i'm using doing this?
Click to expand...
Click to collapse
I don't think it's a ROM problem.
The 2 most common reasons for not working are:
It doesn't work if you have G-Scroll or something similar installed.
When you edit config for an App, this config only applies when "Window Title" and "ClassName" of the foreground window matches what is defined in that Config.
If it doesn't match any config, DredSensor doesn't catch your hard keys.
You can use wildcards in your Config so, for example, if the app you want to configure always changes its title, you can set "*" for window title.
everything gose well in my diamond! Thx!
just a little suggestion : as volume up/down could be very useful in some app (like a game emulator), could you make them configurable in your next version?
nice job!
Furbious said:
I just don't seem to be able to get this to work - I follow the first post to remap the home and back keys to the softkeys, but home always takes me back to touchflo.
Are there any other things I can try, or is it just the ROM i'm using doing this?
Click to expand...
Click to collapse
I make a softreset and works whit no problem, when i click home button open the program i assign.
Doesn't seem to work in Phone screen. I am not sure if it is because it is a dialog class. If this could be made to work, it would be great as when a person has multiple phone numbers you could scroll by pressing right or left key.
Thanks in advance
just tested it with tetris and it worked great. good stuff
Dredger97 said:
I don't think it's a ROM problem.
The 2 most common reasons for not working are:
It doesn't work if you have G-Scroll or something similar installed.
When you edit config for an App, this config only applies when "Window Title" and "ClassName" of the foreground window matches what is defined in that Config.
If it doesn't match any config, DredSensor doesn't catch your hard keys.
You can use wildcards in your Config so, for example, if the app you want to configure always changes its title, you can set "*" for window title.
Click to expand...
Click to collapse
I've nothing like that installed - I've tried wildcards, and soft resetting between altering them, even setting the default so that it should catch any class or window so that the home and back keys are soft keys one and two.
It's semi trapping the window and keys.......I just wonder if your app is not being fed the correct window name/class, or there's some extra characters or something that is fooling it.
Here's an example - setting home and back keys to the softkeys, with a config of * for window, and * for class.
On the touchflo screen, pressing home will take it to the phone screen (correct left softkey action), but once in the phone screen, pressing home takes it to the touchflo screen when it should go to contacts.
If I'm in any other application, it never traps the home key, and will always go back to touchflo. Disabling touchflo doesn't change this, it takes it back to the today screen.
I'm using shak's rom if anyone else can confirm they can get it to work using that one

I want to map X-Panel button. AEButton doesn't do it and I am lost for solution...

I found the answer:
Love your Xperia but find Panels a bit of a gimmick? This little tip will allow you to remap your Xperia Panels button to something a bit more useful.
All you have to do is navigate to:
HKLM\Software\SonyEricsson\PanelManager\ApplicationName
with your favourite registry editor and change the string value there to the path of an alternate executable.
e.g. “\..\Windows\Pie.exe”
The quotation marks and the \..\ part is important and needs to be part of the path used above.
To use the button to access your start menu you could map it to Quickmenu, a popular start menu replacement.
Read more about the hack in this XDA-Developers thread.
Click to expand...
Click to collapse
And here is the thread: http://forum.xda-developers.com/showthread.php?t=448067

Categories

Resources