- the EXTRA_NO_HEADERS flag as no more meaning as we are showing
the Tiles (previously named "Headers") only in the Dashboard
(which is the main Settings screen)
Change-Id: I55656de0d28ca9c84adbe6647d870838b4ac230b
- getNonIndexableKeys(Context) allow a SearchIndexProvider to tell which data
he does not want to index by providing a list of the data keys
- use this new API for SoundSettings and removing KEY_EMERGENCY_TONE related
settings if the device is not CDMA
- add a BaseSearchIndexProvider for code simplification
Change-Id: I23633ace1d7e390ee05fac0a5458a33e04e72d8d
- follow the UX spec by no more using a Drawer
- the Dashboard is now a Fragment that contains the list of Headers
- the search results are also put into a Fragment that is replacing
the initial one (Dashboard or other) when expanding the SearchView
- use a SearchView for query input
- when tapping on a Header or a Search Result, re-launch Settings as
an Activity so that we are benefiting from the Activity stack for
UP affordance and BACK button
- manage UP affordance to show it only when needed
- move some Actions to the Menu in the ActionBar for allowing space
to the Search action and removing some clutter
- fix an issue with the Index and WiFiEnabler and their cached Context
that was not updated when there was a Configuration change
- simplify the SettingsActivity code by extracting some inner classes
Change-Id: I50b5f77bb44a7fade1886114dbbc820609a5e63d
- change the Index SQL model. Add a new "enabled" column.
- use that column for issuing a more restrictive search query
- change the SearchIndexProvider API to pass the "enable" state
- apply it to Bluetooth settings
- refactor the list of indexable resources (SearchIndexableResources)
Change-Id: Ic900fb27cb12a285a80d953aa1aa88f0070cd986
- comply to the SEARCH_INDEX_DATA_PROVIDER
- add to the Index the name of previously paired BT devices
(this will work for now only and only if BT has been on during
the indexing)
Change-Id: I00065db0f4e9657cca3578a2fafa0ec39cfaa432
There was a fundamental flow in the BT code. Basically BluetoothSettings is using
a singleton BluetoothDiscoverableEnabler.
BluetoothDiscoverableEnabler is keeping (thru its constructor) a reference on a Context
for registering/unregistering some broadcast receiver. BUMMER! When you change orientation
(or more generally the device Configuration), your Context is no more the same!
Hence the crash as we were trying to unregister a Receiver on a Context that is no more valid.
Fix that issue by passing an updated Context to the BluetoothDiscoverableEnabler.resume() API.
Bug #12991455
Change-Id: I77db15d2b59b6dd973907e26f9e6bb022202a8b5
- get rid of PreferenceActivity as much as we can and use fragments instead
- add Drawer widget
- add Dashboard high level entry into the Drawer (but this is work in progress and would be done in another CL)
- add bypass of fragment's Header validation when launched from the Drawer but *force* validation if external
call thru an Intent
Be aware that WifiPickerActivity should remain for now a PreferenceActivity. It is used by SetupWizard and should
not trigger running the SettingsActivity's header building code. SetupWizard is a Home during the provisionnig process
and then deactivate itself as a Home but would make the Home header to appear in the Drawer (because momentarily we
would have two Home).
Also, verified that:
- the WiFi settings still work when called from SetupWizard
- when you have multiple Launchers, the Home header will appear in the list of Headers in the Drawer
Change-Id: I407a5e0fdd843ad7615d3d511c416a44e3d97c90
When these screens are locked down with user restrictions,
it should prompt the user for the restrictions pin before allowing
access to the settings screen.
Change-Id: Iadbb087da2d9470b855ea0bea89f2da1ffb9e854
When a user has the user restriction DISALLOW_CONFIG_BLUETOOTH
- Remove all the menu items for searching and other config
- Hide "available" but non-paired devices
- Remove settings button from paired devices
- Remove ability to make the device visible to others
Change-Id: Icaebf29d3cce55d924fdd65449447b5b7a438bbe
- When there are no available Bluetooth devices, we show
"No Bluetooth devices were found nearby" as a preference item after
the scan completes. Update the layout for this Preference item so
that the text is centered and doesn't highlight when touched.
- Fix slow responsiveness on scanning caused by repeated removal of
"No Bluetooth devices were found" preference item on every call to
onBindView().
- If no devices are paired, don't restart the scan on every rotation.
Bug: 5173935
Bug: 5055460
Change-Id: I52fb2d52f315c5e793f08499146842d54c5c3ead
- Pair one devie, then turn off BT then reboot the phone
and enter Bluetooth settings screen and turn on BT.
The last paired device will not be displayed in paired list.
- After onResume() is called, the list is shown.
- The reason is that mDevicePreferenceMap is not empty. The paired
devices are cached when BT is off and then skipped when BT is
turned on and updateContent() is called again.
- Make the mDevicePreferenceMap clear when updateContent() is called
and adapter state is BluetoothAdapter.STATE_ON.
Change-Id: Ia745e02bcb4e21a54ccc8477a4dfbad1fa5aed17
Signed-off-by: jhtop.kim <jhtop.kim@samsung.com>
- When trying to pair with any device, if bond state changes
device scan will be started automatically.
- add some flag to check proper scan time and to prevent unnecessary device scanning.
Signed-off-by: jhtop.kim <jhtop.kim@samsung.com>
Change-Id: I4977ec122105f33cdd25a4f5c9fed59dda916379
- Add some codes preventing setting crash when rotating the screen
when the Rename device or Visibility timeout dialogs are visible.
Change-Id: I5e142a5d869a0d5c91c6ace80093d09178d79558
Signed-off-by: jhtop.kim <jhtop.kim@samsung.com>
- Change Bluetooth profiles screen to match ICS wireframes
- Remove BluetoothProfilePreference.java (no longer used)
- Remove "Pair with this device" summary below every unpaired device
- Remove "Paired but not connected" summary below unconnected paired devices
- Fix auto connection after pairing (reuse existing CachedBluetoothDevice)
- Add "Connected (no phone/media)" summaries based on ICS wireframes
- Fix visibility timeout strings.
- Fix crash when starting Bluetooth from Settings shortcut widget.
Bug: 5064139
Bug: 5064324
Bug: 5080404
Bug: 5093513
Bug: 5104485
Change-Id: Ie87103e183ce414c86cb1831a38ef0178b1b1292
- Remove BluetoothFindNearby.java (no longer used)
- Show message when Bluetooth is turning off
- Fix case where device name sometimes didn't show when turning BT on
- Disable "Rename device" and "Visibility timeout" menus when BT is off
- Remove "Got onDeviceAdded, but cachedDevice already exists" log message
- Never show "Rename device" in action menu (bug 5064378)
- Show discovery time remaining as "m:ss", not "mm:ss" (bug 5064104)
Bug: 5064378
Bug: 5064104
Change-Id: I79609dfdad61993a28cff64c9e082870ff74d180
* Change Bluetooth pairing dialogs to match ICS wireframes.
* Default to numeric soft keyboard for PIN entry, and add checkbox
to allow user to switch to alphanumeric keyboard if necessary.
* Move all Bluetooth advanced settings into action bar menu.
* Toggle visibility by touching "My device" entry in devices list.
Change-Id: Ic2377eb4364f41d215181cb1e3933997c9db9106
Two lists: paired devices and available devices.
New item at top for the device itself (not connected to discoverable, this is a larger
refactoring).
New settings icon.
Change-Id: I788a6c0afdb07309d449a4d41a02cf8480c95a37
Paired devices are listed first (from cache), followed by unpaired ones.
A scan is only started on user request or when there is no paired device
(should it be when there is no paired *connected* device?).
Wrench icon only displayed for paired devices.
Wrench click listener no longer uses mDeviceSettings which is unreliable
with ListView view recycling.
Fixed blinking ProgressCategory when the category was first in the list.
Change-Id: Ie749883426c12bd354da64733bd04b00304bc1f5
Made menu item visible to force action bar, changed style.
Also change parent_fragment for items that have been moved to top level (wifi,
bluetooth, development, battery).
Change-Id: I62932ba55356abdfbf94942f5b4efaa0f15dbd6a
Fix NPE when entering Settings app in the SDK (and for devices without
Bluetooth). Also remove the "Bluetooth settings" item in addition to
the Bluetooth toggle item from Wireless settings when BT is missing.
Bug: 4149307
Change-Id: Iecc5960a193cf88664d3217b4d7bdbc2276dabc0
Major refactoring of Bluetooth settings classes.
- Moved all functionality from LocalBluetoothManager into new
LocalBluetoothAdapter and LocalBluetoothPreferences, and into
existing classes.
- Refactored functionality from BluetoothEventRedirector into new
BluetoothEventManager class, deleting the original version. New
version uses a HashMap from action Strings to implementers of the
BluetoothEventManager.Handler interface.
- Created new BluetoothDiscoveryReceiver to update shared preferences
timestamp for Bluetooth discovery start/finish. This is the only event
handling we need to do when the settings app is not visible, so it has
its own receiver entry in AndroidManifest.xml. Edits are written using
QueuedWork.singleThreadExecutor(), which BroadcastReceiver knows about
and will wait for completion, eliminating the need for PendingResult.
- Miscellaneous cleanups to code style and logic for readability.
- Pulled some large switch statement code blocks into new methods.
- Changed all Bluetooth state references to the new BluetoothProfile
constants.
- Changed use of deprecated Notification constructor in
BluetoothPairingRequest to use Notification.Builder.
- Moved Utf8ByteLengthFilter helper function from BluetoothNamePreference
into its own class, and moved test cases into the same package.
- Moved all LocalBluetoothProfileManager functionality related to
specific profiles into new top-level classes (A2dpProfile, etc.), all
implementing the LocalBluetoothProfile interface.
- Moved all UI-related methods from CachedBluetoothDevice into the class
that uses the method, or into the static Utils class for shared methods.
Change-Id: I6d49b7f4ae0c7d7dcf62551ee40b51ecb5fe4f47
Add handler to send an intent to the Bluetooth OPP app to show the
list of received files to the user.
Bug: 3167219
Change-Id: I59e18559a0c35add7f1be56a5f040dae4dccc7f1
Close the scan screen after successful pairing, and remove a
device from the list of paired devices after unpairing.
As part of the fix, BluetoothSettings was refactored into a parent
class, DeviceListPreferenceFragment, and three subclasses for each
variant type: BluetoothSettings, BluetoothFindNearby, and
DevicePickerFragment, replacing the checks against mScreenType with
custom logic in the child classes.
Bug: 3325848
Change-Id: If64fddc3ba5b4f1136451491c7d5a1139b696e47
Fix for reported bug where settings app crashes while trying to share
a picture. Bug report showed IllegalStateException thrown with message
"Got onDeviceAdded, but cachedDevice already exists." Changed code to
print an error message to the log and ignore the unexpected event,
rather than throwing an uncaught exception that crashes the app.
Bug: 2192884
Change-Id: I016be6a1616b317b2289768d18ae9f069a49445e
- Enable support for reverse tethering in BT settings.
- Add string resource for "Auto connect" preference.
- Remove unused imports and other minor cleanups.
- Add isConnectable() and isAutoConnectable() methods to Profile
enum type and remove isConnectableProfile() method.
Change-Id: Ie606db04028a8278e98231f0671a388671f2f067
Remove obsolete Bluetooth tethering settings screen. BT tethering can
be turned on and off, but the connection must be initiated by the
remote device. For reverse tethering, there will be a checkbox for
that profile in the regular Bluetooth device settings screen.
Bug: 3283928
Change-Id: Ic25139f8862b305feb0381e61c24b7783fad2366
- Removed context menu logic for long press (no longer used).
- Converted device picker to run in its own Activity, using a dialog
theme on large screen devices and full-screen on phones.
- Removed unused resources.
- Add device to "Paired devices" list when pairing is initiated by the
remote device.
- Return to Bluetooth settings pane after successfully pairing a new
device from the "Find nearby device" pane.
- Add support for renaming devices (TODO: persist the custom name and
update the "bread crumb" in the action bar to the new device name).
- Add support for incoming file transfer and auto connect checkboxes
in DeviceProfilesSettings.
- Show available and connected device profiles as icons instead of
summary text. Available but disconnected profiles are drawn in gray.
- Fixed bluetooth_notif_message to include the device name as a parameter
instead of appending the name to the end of the localized string.
- Changed some fields from private to package scope for more efficient
access from inner classes.
Bug: 3137982
Change-Id: Ic2d6ee5be60c9c5b3f3a8a58846d58efedfa5c93
Allow individual Bluetooth profiles to be connected/disconnected from
the device's settings pane.
Bug: 3137982
Change-Id: I21512c5bf965fc523f3dc1e83d029b16b5e22440
Add UserLeaveHintListener.java, so that the settings won't use
its implementation around Activity#onUserLeaveHint().
Also fragmentize bluetooth tethering screen.
Change-Id: Id06ae3161fbdb5854ddb7a257f464fb16ea9b089