Questions tagged [preference]
445 questions
9
votes
3 answers
How to set edittext preference summary and have it stick
I have gone back and fourth on this and I just can not get it. I am setting up my settings using a preference fragment. I can get the settings to work and I can even get the "summary" to update when I make the change. But if I leave the settings…

user3423167
- 101
- 1
- 1
- 3
8
votes
1 answer
Android preference title/summary text style
I have a couple custom preference items -- one that displays a swatch of the currently selected color, and another one that displays a thumbnail.
I have a custom layout for these that matches up very well, and have found that I can make the text…

Terazilla
- 81
- 3
8
votes
1 answer
Define Default Activity (when app starts) programmatically
My application is composed by a few activity.
Activity A is my main menu with some icons.
This Activity can launch depending on which icon you press: Activity B,C,D,E or F.
That's fine and really easy, Activity A is the default one.
Now, I made an…

Waza_Be
- 39,407
- 49
- 186
- 260
8
votes
1 answer
Android - Should I keep using PreferenceActivity?
My app supports from 2.2 to the lates Android version.
The thing is that for Settings page, I am using PreferenceActivity now.
However, as you know, many of its methods are deprecated and they tell me to use Fragment based settings.
However, I found…

user2062024
- 3,541
- 7
- 33
- 44
7
votes
2 answers
Preferences of varying height within a PreferenceActivity
I have a custom class that extends Preference that I'm using in conjunction with a PreferenceActivity.
When I try to adjust the height in the layout my Preference is using (with a static layout_height or with wrap_content) it is always displayed in…

Nick
- 8,483
- 10
- 46
- 65
7
votes
3 answers
Setting preference layout and changing the attribute in it
is it possible to access programmatically a layout which is set to a Preference?
Here is what I have, a very simple project - proof of concept
The Preference Activity:
package com.example;
import android.os.Bundle;
import…

Nik Chankov
- 6,049
- 1
- 20
- 30
7
votes
3 answers
Launch Activity from Preference Activity causes Permission Denial Exception
I'm having a bit of a problem here. What I want to do is launch an Activity from within the PreferenceActivity. So my preference.xml which holds the preference layout looks like this:

moritz
- 2,448
- 1
- 20
- 25
7
votes
1 answer
file chooser intent opened from preferences
I'm trying to learn about Settings UI building, and I see in the android docs that a preference can be an Intent, but what I wonder now is if that Intent can return a preference value (such as a filename picked by starting a file chooser…

user1160711
- 463
- 1
- 5
- 11
6
votes
7 answers
How to clear preference iOS push notifications for my application?
Hello When the application is installed, it asks the user for permission to send push notifications.
I'm testing my application. But after removing it from the device and then install it no longer asks for permission.
How do I remove these settings…

EndyVelvet
- 421
- 1
- 4
- 14
6
votes
1 answer
Can't run Preference Pane application
I created a new Xcode Preference Pane project which I aim to run in the System Preference application.
I have made one modification to the project's build settings:
Changed Base SDK to Mac OS X 10.6 from 10.7 (Since I want to keep compatibility…

Rami
- 381
- 2
- 4
- 15
6
votes
3 answers
Android SeekBarPreference
I'm currently trying to implement SeekBarPreference class using http://android-journey.blogspot.com/2010/01/for-almost-any-application-we-need-to.html tutorial with RelativeLayout. First problem is TextView preferenceText isn't showing at…

Lovro Pandžić
- 5,920
- 4
- 43
- 51
6
votes
3 answers
Custom DatePicker as Preference does not keep value when user edits value in field
I created a DatePickerPreference, i.e. I extended DialogPreference and created a DatePicker object inside and had it working almost perfectly. It changes values when you click the arrows up and down and saves the value you select.
However, if you…

OtavioKR
- 61
- 1
- 5
6
votes
3 answers
onProgressChanged() of a SeekBar is called twice
I have created a Custom SeekBarPreference such that it displays a range of time to be selected from (say 0.2 sec to 2.2 sec). My problem is onProgressChanged() is called twice - once with progress = 0 and the second time with progress = "actual…

yadav_vi
- 1,289
- 4
- 16
- 46
6
votes
1 answer
Read SharedPreferences when you haven't set the name of the file
When you createa a PreferenceScreen on Android, your application creates a default SharedPreferences file for the settings.
I want to read this name, or get a reference without specifing the name.
Currently I use:
SharedPreferences prefs =…

Pentium10
- 204,586
- 122
- 423
- 502
6
votes
2 answers
The method getinstance(Context) is undefined for the type AccessibilityManager
I'm trying to create my own ImagePreference that I will use in my app preferences in order to pick the picture the user chooses to represent himself.
I'm not too sure about what I'm doing, but basically I'm mimicking some other preference classes.…

ivansiiito
- 133
- 2
- 10