Commit Graph

21 Commits

Author SHA1 Message Date
Abhijeet Kaur
d7e44c7b3a Remove enum logic from callers of requestbugreport()
Make callers use wrapper functions in ActivityManagerService.java.

The code to send broadcast to trigger API workflow (after checking the API
flag) is added in requestBugreport() in ActivityManagerService.java.
Remove that logic from this file.

Bug: 137825297
Bug: 141355059
Test: builds and full/interactive bugreports work as expected

Change-Id: Ibc305e4aca7d38fd4878b60f3f7f8c3274719c13
2019-09-23 13:47:20 +00:00
Abhijeet Kaur
624832e5de Turn on feature flag to use bugreport API by default
Bug: 136548098
Test: build, flash, take bugreport from Settings uses API workflow by
default. Turning off the feature flag from Settings uses old bugreport
workflow

Change-Id: Icbfa82e2dc218769fdcc03d15ce3cc7bb50cc4ef
2019-08-08 15:14:39 +01:00
Abhijeet Kaur
59be362d67 Use USE_BUGREPORT_API flag from FeatureFlagUtils
To avoid flag duplication, this flag is moved to FeatureFlagUtils.java
where other callers can also use this flag. Using this flag's value from
FeatureFlagUtils instead of the local FeatureFlag file in Settings.

Bug: 136548292
Test: Settings can still access this feature flag as before
Test: Builds and API workflow gets triggered by turning on the flag
Change-Id: I60e4d96033219c934a43e728705fee93e338d60e
2019-08-07 16:47:28 +01:00
Abhijeet Kaur
c5c84bc405 Trigger a bugreport directly from shell
Send broadcast to shell, so that it makes a call to bugreport API
directly.

Permission protected call is made so that not any app can send this
broadcast intent to shell.

Use Settings feature flag to turn on this workflow and leave the old workflow
untouched.

Bug: 123617758

Test: build and manual test by triggering bugreports from the device
Change-Id: Iec43fa1e5e379e2f5520a48f7fe036d59e2a8d28
2019-05-28 14:20:16 +01:00
Fan Zhang
31b210017b Migrate all MetricsProto enums to SettingsEnums
Bug: 122855168
Test: rebuild
Change-Id: I962d9a71179f86b7cae9dc5e9a00e0aa1557dc76
2019-01-17 14:55:42 -08:00
Fan Zhang
23f8d59d02 Sort imports
Having consistent import order will reduce chance of merge
conflict between internal and external master

Test: rebuild
Change-Id: I0b1a170967ddcce7f388603fd521f6ed1eeba30b
2018-08-28 22:13:15 +00:00
tmfang
27c84de325 Settings Fragment Migration (Build pass app)
This patch focused on fixing compile errors and some runtime errors.

Test: We can't test it now. But we will have an integration test later.
Bug: 110259478
Change-Id: I16c471ddcd0fa1460c665b7f74d86fcace5ee67b
2018-07-11 18:24:51 -07:00
Juan Lang
4482812cb1 Use SettingsLib's versions of Custom* classes.
Test: make RunSettingsRoboTests
Change-Id: I2584e820b72bb4672c53fd1a9f63c7f1662e0809
2017-06-21 12:07:50 -07:00
Sudheer Shanka
acb1a61f3f Update usage of ActivityManagerNative.
Bug: 30977067
Test: N/A
Change-Id: I46e37a09cff059d2784a819bc2651d6973fbd268
2016-11-14 12:59:11 -08:00
Tamas Berghammer
265d3c2a0c Update package names to work with the proto3 compiler
Bug: b/28974522
Change-Id: I5f3adf4946ee4ba1e09e4f40afe83c151405972a
2016-11-08 14:06:17 +00:00
Fan Zhang
aa71afe597 Use MetricsFeatureProvider for logging in Settings.
Bug: 31664539
Test: make RunSettingsRoboTests for regression
Test: adb logcat -b events | egrep "(sysui_|notification_)" for
      verifying log

Change-Id: Id944be7c4ff9911aebee481c2df485542f1318f0
2016-09-23 08:37:37 -07:00
Felipe Leme
fce3e960fd Remove delay from interactive bugreport.
The delay was useful when the interactive bugreport took an initial
screenshot, which is not the case anymore.

BUG: 30429546
Test: manual

Change-Id: I648db4e1acdea3aa89df9205148cac43880763be
2016-09-21 10:36:39 -07:00
Felipe Leme
34c5d3aa86 Fixed context reference.
BUG: 27608886
Change-Id: I2d2e2393ce52f4461dce276231cbc90563897ffd
2016-04-25 09:27:40 -07:00
Felipe Leme
038bf65686 Makes call to MetricsLogger right away when taking bugreports.
Previously the call was made on takeBugreport(), which caused a NPE on
interative report calls because the context was null since it was
handled by a handler.

BUG: 27354167
Change-Id: I19e91cb4b43a7aa0bfcdab440c4cd4225110fdfb
2016-02-25 11:37:56 -08:00
Felipe Leme
7b11c500f6 Logs bugreport type metrics.
BUG: 26759986
Change-Id: Ie4045301fadfb608aa694bc9a9756a703dd194ed
2016-02-23 09:09:13 -08:00
Michal Karpinski
c78b926621 Adjusting call to AMN#requestBugReport()
Bug: 26152603
Change-Id: I5cf66889732aaca2479f09ebacb7beb36f84ea58
2016-01-08 17:46:26 +00:00
Felipe Leme
834496f7fc Changed dialog shown from "Take Bug Report" to display 2 options:
* Normal Report: the new, enhanced option is more user-friendly (it
  shows a system notification with the progress, allow user to cancel,
  etc...), at the cost of consuming more resources. When this option is
  selected, the bugreport will be delayed 2 seconds so user can dismiss
  the Settings app before a screenshot is taken.

* Emergency Report: a lighter approach that is less intrusive and
  should be use when the phone is unresponsive or too slow.

BUG: 26034608
BUG: 11665244

Change-Id: If9c0242a163c8c33adecfc8a65af561e839bab8d
2015-12-21 08:15:17 -08:00
Felipe Leme
5062435cfc Changed "Take Bug Report" action to call 'bugreportplus'.
'bugreportplus' is more user-friendly (it shows a system notification
with the progress, allow user to cancel, etc...), at the cost of
consuming more resources. As such, the "Take Bug Report" UI will be
changed to offer the user a combo with these 2 options, but for now it's
always going to be 'bugreportplus'

BUG: 26034608
Change-Id: Idbb325fe7cd18e487197b2fb79cfc264e9859570
2015-12-08 16:01:20 -08:00
Jason Monk
39b467482d Depend on support lib preferences
Bug: 24576551
Change-Id: Ic6190bacd3f7582c9bbc8de972da4612bd92421e
2015-10-13 10:12:20 -04:00
Dianne Hackborn
2d803a3931 Add dev setting to enable global actions bug report button.
Change-Id: I3768f95e1c6fbec9c10186093e5e1d48b0ef6ae4
2012-08-07 11:26:32 -07:00
Dianne Hackborn
fd8c315573 Implement issue #6819955: Add button to take bug report.
Change-Id: Ic615180121d4db52f92aa8264d95d790de5fff9d
2012-07-13 16:10:16 -07:00