Shutter button - Xperia Play Android Development

I was looking for a way to modify the standard shutter button. I noticed the following line in the source code for the 2.3.2 official camera app:
Code:
mShutterButton = (ShutterButton) findViewById(R.id.shutter_button);
It seems to look if something is set as shutter button (I'm not great with programming though) and I was wondering if the R button could be set as the standard shutter button. It's in the perfect place and I'm abit amazed SE didn't make it the shutter button.
I am aware that there are camera apps for download that allow button mapping but I just wondered if it was possible to make the R the standard shutter button to use it with all apps and it would be nice to have in costum roms.
So if anyone could fix this or atleast set me or somebody else in the right direction to look for (like what file to edit) that would be awesome.

probably wrong place to mention this, but the X button is already mapped as the shutter button

Well, maybe it will, if not, thanks for the tip anyway, I could sue it personally

Related

Disable volume button and enable audio note taking instead?

Is it possible to disable the volume button and enable it instead to start/stop audio note taking?
Thanks
I want todo this exact thing. Any luck with responses?
No.
greatest invention
This is the greatest thing I've been told. Go get a pda, and make notes while your driving etc..
And then they go and remove the function. And replace it with a volume button that doesn't even work properly!!
Martin
Try this...
I dont't know if it will work but maybe you could try this little button mapping tool:
http://romfour.free.fr/adrom/products/btmap.htm
Give us an update if it worked!
No it doesn't. They seem to have removed the mapping id for the volume button. You used to be able to map it through control pannel in really old versions.
Anyone know what it used to be?
Workaround
Hi,
AFAIK it's not possible to use the volume button for other functions, but you'd be able to use another button for this.
I like to have the most common things within some klicks, so I used the calendar-button for audio-recording (you can switch to the calendar by clicking your appointments on the today-screen anyways).
Settings -> Buttons: Set Button 1 to Recording (not sure if the translation is correct, I'm using the german XDA)
Thanks
Thanks for the workaround, yes it works fine, even if I was expecting a start/stop function rather than a push and hold. But now I'm using it I prefer this method.
Mame can remap the volume button so it must be possible.

[Q] Remap camera button

I'd like to remap the camera button to launch the voice recorder when suspended, but available as shutter button when in the camera app. Can this button be context sensitive like this?
I found a key mapping in the /system directory, and saw a keycode with the word CAMERA next to it. Is it just a matter of replacing CAMERA with the appropriate voice recorder binary?
Thanks!
I don't believe there is any context sensitivity - however, you can map the camera half-press to the shutter, and a full-press to a voice recorder?
I had to remap my half-press camera button to the "BACK" action when my capacitive "back" button broke on my streak. You'll have to get root, and afterwards you can modify /system/usr/keylayouts/{qwerty,surf}.kl I believe.
Key 52 is the halfpress I think.. 52, or 59. Dig around the .kl files and search for "FOCUS" and "CAMERA" to see which key IDs map that button.
btw, i grew up near/in cerritos from 1986-98. I miss that area very much, esp. during those times. /me waves
kertong said:
I don't believe there is any context sensitivity - however, you can map the camera half-press to the shutter, and a full-press to a voice recorder?
I had to remap my half-press camera button to the "BACK" action when my capacitive "back" button broke on my streak. You'll have to get root, and afterwards you can modify /system/usr/keylayouts/{qwerty,surf}.kl I believe.
Key 52 is the halfpress I think.. 52, or 59. Dig around the .kl files and search for "FOCUS" and "CAMERA" to see which key IDs map that button.
btw, i grew up near/in cerritos from 1986-98. I miss that area very much, esp. during those times. /me waves
Click to expand...
Click to collapse
Thanks! Am I right that I would replace that action with the binary name of the voice recorder? Or is it the apk name?
Wife said we "had"to move to Cerritos, so we did.
I have done this same thing.
It is very easy to do with the Tasker application.
I have set mine so that when im in the car (with my own car mode set on) that the camera button brings up a choice of the dialer, call log or contacts. yet it still functions perfectly when in the camera app.
the_didge said:
I have done this same thing.
It is very easy to do with the Tasker application.
I have set mine so that when im in the car (with my own car mode set on) that the camera button brings up a choice of the dialer, call log or contacts. yet it still functions perfectly when in the camera app.
Click to expand...
Click to collapse
Please describe step-by-step what you did! My ROM is 2.1 (o2), 8105 build.
I tried tasker but I dont see how to remap the Camera (FOCUS) button.
I changed an event (hardware - CAMERA Button) and added an action (load App) then applied.
The notification says, no profie activated? Why?
kertong said:
I don't believe there is any context sensitivity - however, you can map the camera half-press to the shutter, and a full-press to a voice recorder?
I had to remap my half-press camera button to the "BACK" action when my capacitive "back" button broke on my streak. You'll have to get root, and afterwards you can modify /system/usr/keylayouts/{qwerty,surf}.kl I believe.
Key 52 is the halfpress I think.. 52, or 59. Dig around the .kl files and search for "FOCUS" and "CAMERA" to see which key IDs map that button.
btw, i grew up near/in cerritos from 1986-98. I miss that area very much, esp. during those times. /me waves
Click to expand...
Click to collapse
Hey Kertong, needing to do same thing. Replaced my screen and keypad now only performs menu. I am in shell trying to find the right action. Can you describe what you edited the .kl to?
Option 1
2 apps combined together can remap camera
button remapper - remap camera to search fn
launcher key to set search to any app u want
Option 2
Use tasker
Tried Tasker, great program just couldn't get it to work right, but will be a great application when I get it all setup.
My resolution.
Instead of using applications...
I did 'adb shell'
went to /system/usr/keylayout
did 'vi surf_keypad.kl'
And edited key 212 which is Camera, with Back.
Although now the softpad doesn't function as Menu only. Atleast I can go back now.!
the_didge said:
I have done this same thing.
It is very easy to do with the Tasker application.
I have set mine so that when im in the car (with my own car mode set on) that the camera button brings up a choice of the dialer, call log or contacts. yet it still functions perfectly when in the camera app.
Click to expand...
Click to collapse
wyx said:
Please describe step-by-step what you did! My ROM is 2.1 (o2), 8105 build.
Click to expand...
Click to collapse
Seconded. Share!
http://forum.pocketables.net/showthread.php?t=9680

Use Volume Rocker as Camera Button

Hey guys does anyone know if there is a possibility to use one of the Volume Rockers as a Camera Button?
The other threads in the Droid forums didn't bring anything up but maybe you know a way?
I don't really like soft keys to use the camera because you will always screw up the pictures.
Also it would be possible to shoot pictures under water with such a key.
The touchscreen doesnt work in water
thanx
Try this app : http://forum.xda-developers.com/showthread.php?t=850464
thanx for the quick answer
Been looking for the exact same thing. Thanx a lot for the link, will try it asap.
:=)
can someone just tell if it worked?
would be great :=) thanks :=)
yes it works, set the button to none in remapper or the camera can launch while screen off. then you don't have a volume up button, so I use tasker to create a widget to put all the volumes to high.
use last VIGNETTE apk, it use camera button from volume! great!
marcoser said:
use last VIGNETTE apk, it use camera button from volume! great!
Click to expand...
Click to collapse
u mean the app from the market which costs money? sry.. don't want to invest for basic functions :=)))
but.. i'm not quite sure how to configure the camera button.. will play around when i got time.. if anyone has the knowledge and the time to post the procedure for the above tool :=) would be great...
my problem: from the screenshots and the description.. i'm not quite sure how to define that the volume button actually gets used as "touch-screen-action"? :=/
greets...
How would anything get done if we all needed blow by blow instructions.
Read the post, install the APK, it's an app not a string of ADB commands.
Scroll down to volume up button, select it, tell it to be a camera button in the drop down, apply. If you don't want the reverse option on the note bar then configure app.
BTW the search button won't configure withthis app.
pdjm43 said:
How would anything get done if we all needed blow by blow instructions.
Read the post, install the APK, it's an app not a string of ADB commands.
Scroll down to volume up button, select it, tell it to be a camera button in the drop down, apply. If you don't want the reverse option on the note bar then configure app.
BTW the search button won't configure withthis app.
Click to expand...
Click to collapse
Very nice instructions my man and just so everyone else knows there is actually an app in the market for this just search defy you'll see it it saves the photos to your sd it works
Sent from my MB525 using XDA App
Good! Though I find the vol rocker too hard to press for taking photo

Camera hard button

Unless I'm mistaken, what I did to the camera there is supposed to make it so the search button opens the camera and takes the pictures. Well, it does open the camera, but it doesn't take the pics. Am I wrong about it making it so it also takes pics? And if that's not the right way to do it, does anyone know how?
A BEAST NEVER SLEEPS
jakereeves31 said:
Unless I'm mistaken, what I did to the camera there is supposed to make it so the search button opens the camera and takes the pictures. Well, it does open the camera, but it doesn't take the pics. Am I wrong about it making it so it also takes pics? And if that's not the right way to do it, does anyone know how?
A BEAST NEVER SLEEPS
Click to expand...
Click to collapse
When you make a button open the camera thats using the long press shortcut setting, so you for example you hold the search key for 2 sec and it opens the camera. And as far as the button used for taking the picture itself, that is a setting in the actual camera app that you can set in some roms. I know with CM7 you can set it to have the search key, volume key, or power button snap the picture.
Kev13131 said:
When you make a button open the camera thats using the long press shortcut setting, so you for example you hold the search key for 2 sec and it opens the camera. And as far as the button used for taking the picture itself, that is a setting in the actual camera app that you can set in some roms. I know with CM7 you can set it to have the search key, volume key, or power button snap the picture.
Click to expand...
Click to collapse
Wow, really? I did not know about that setting. Thanks!
THE BEAST
camera button
i miss the camera button on my Droid X

menu button as camera button

I apologize if this has been brought up
but would it be possible to use the menu or volume buttons as a camera button?
+1. any option that doesn't involve rooting the phone?
Use HyperX's Modded camera. It will provide you with better quality and many other additional features along with the ability to use Volume buttons to shoot photos.
Have a look at his HOMEPAGE
There is no way to do this without root.
I strongly think that Samsung should add dedicated camera key.

Categories

Resources