Add is_read_only to DatabaseOpenedEvent

On Android, when a database is opened as Read-Only, it is not necessarily actually read-only. It is just not guaranteed to be writable.

If we do end up with an actual read-only database, we should be able to show the user
that the db was opened as read-only.

This change adds a `is_read_only` field to the DatabaseOpenedEvent, and it also changes logic that sends this event:

Whenever a db is opened or closed, we check if the type (forced, rea-only or writeable) has changed since the last time we sent an event for this DB.

Bug: NA
Test: Added
Change-Id: I436c1d2b18667063ed25d400ab75371069d03f1c
5 files changed
tree: cf2d05820c3b83ee597d502ac1d0ee217bc1159e
  1. .idea/
  2. adb-proxy/
  3. adblib/
  4. adblib-ddmlibcompatibility/
  5. adblib-tools/
  6. annotations/
  7. apkparser/
  8. app-inspection/
  9. apps/
  10. aspects_agent/
  11. bazel/
  12. build-analyzer/
  13. build-system/
  14. chunkio/
  15. chunkio-processor/
  16. common/
  17. ddmlib/
  18. debugger-tests/
  19. debuggers/
  20. declarative-gradle/
  21. deploy/
  22. device-provisioner/
  23. device_validator/
  24. draw9patch/
  25. dynamic-layout-inspector/
  26. echo-sample/
  27. emulator/
  28. environment-services/
  29. external-annotations/
  30. fakeadbserver/
  31. fakeandroid/
  32. firebase/
  33. flags/
  34. game-tools/
  35. gmaven/
  36. intellij-bazel/
  37. intellij-native/
  38. jaxb-inheritance-plugin/
  39. jdwp-packet/
  40. jdwp-scache/
  41. jdwp-tracer/
  42. jobb/
  43. kotlin-multiplatform-models/
  44. layoutlib-api/
  45. layoutlib-extensions/
  46. legacy/
  47. lint/
  48. manifest-parser/
  49. misc/
  50. mlkit-common/
  51. multipreview-asm/
  52. ninepatch/
  53. owners/
  54. perf-logger/
  55. perflib/
  56. pixelprobe/
  57. preview/
  58. process-monitor/
  59. profgen/
  60. profiler/
  61. repository/
  62. resource-repository/
  63. sdk-common/
  64. sdklib/
  65. signflinger/
  66. standalone-render/
  67. studio-grpc-testutils/
  68. testing-infrastructure/
  69. testutils/
  70. third_party/
  71. threading-agent/
  72. threading-agent-callback/
  73. tracer/
  74. transport/
  75. usb-devices/
  76. utp/
  77. vector-drawable-tool/
  78. wizard/
  79. yourkit-controller/
  80. zipflinger/
  81. .editorconfig
  82. .gitignore
  83. adt.iml
  84. BUILD.bazel
  85. contributing.md
  86. navbar.md
  87. PREUPLOAD.cfg
  88. README.md
  89. source.md
  90. studio.md
README.md

tools/base

This project contains:

  • Common libraries that are shared between any of the IDE (Android Studio), the build system (The Android Gradle Plugin) and SDK components that will be released from studio-main (e.g. the standalone SDK manager). This includes:
    • Instant-run-libraries
    • SDK management libraries
    • The manifest merger
    • Common libraries
    • Common test utilites
  • The build system
  • The new profiler