Commit Graph

448 Commits

Author SHA1 Message Date
Mis012
fea7a9e021 LayoutInflater: add AOSP boilerplate, it seems this file has large portions copied from AOSP 2024-04-07 23:23:31 +02:00
Mis012
b229d83ad8 GskCanvas: implement drawRect 2024-04-07 23:23:30 +02:00
Mis012
677ff43a20 ColorDrawable: add a draw method
we don't use this directly, but it can be called by an app
2024-04-07 23:23:30 +02:00
Mis012
b1d4a69c6b Activity: implement getTitle/setTitle
also set the title from AndroidManifest.xml
this is used by some androidx AppCompat widgets
2024-04-07 21:42:42 +02:00
Mis012
1e64babfd4 borrow AnimationDrawable from AOSP 2024-04-03 01:55:03 +02:00
Mis012
04ee40d010 ViewGroup: make updateViewLayout actually update the layout 2024-04-03 01:55:03 +02:00
Markuss Broks
1b1f026e76 implement android.app.ApplicationErrorReport 2024-04-01 19:41:06 +00:00
Markuss Broks
24e8743cc1 Context: add the input service tag string 2024-04-01 19:41:06 +00:00
Markuss Broks
ad4de8edc4 ActivityManager: add a stub for MemoryInfo 2024-04-01 19:41:06 +00:00
Markuss Broks
4b2c1835f7 AudioManager: add a stub for isWiredHeadsetOn 2024-04-01 19:41:06 +00:00
Markuss Broks
46140d44e3 Window: stub setFormat() 2024-04-01 19:41:06 +00:00
Julian Winkler
654d551377 View.setTranslationY(): queue allocate when called on CoordinatorLayout
androidx adjusts the translation a little bit and immediately
reverts it to trigger a layout pass on the CoordinatorLayout.

Calling gtk_widget_queue_allocate here makes CoordinatorLayout behave
correctly, but it causes strange issues with other Views. Therefore, it is
done only for CoordinatorLayouts for now.
2024-03-28 20:50:05 +01:00
Julian Winkler
9b9e046d68 implement View.getLocationInWindow() and MotionEvent.offsetLocation()
This is needed for NestedScrollViews to detect and correct parent scroll offset
2024-03-28 20:50:05 +01:00
Julian Winkler
8f770d38d1 implement ViewGroup.removeViewInLayout() 2024-03-28 20:50:05 +01:00
Julian Winkler
2879e03120 hack: make GestureOverlayView measure 0 x 0
This restores the behavior before the "remove View.haveComplexMeasure"
commit. This hack is still needed as GTK doesn't allow unhandled events
to propagate to a sibling in the view hierarchy.

This fixes input events in Flappy Bird
2024-03-25 19:43:35 +01:00
Julian Winkler
8eb0c0a3c1 implement ColorFilter in GskCanvas
This is needed to make icons follow night mode setting
2024-03-24 22:13:28 +01:00
Julian Winkler
ad266c7821 add support for custom Java Drawables
This is made possible, by adding a second Canvas implementation which
can be used to render directly to GdkSnapshot objects

For now the only implemented method is drawBitmap(), this is already
enough to make VectorDrawableCompat functional
2024-03-24 22:13:28 +01:00
Julian Winkler
0b78cbcc55 some graphics API stubs 2024-03-24 22:13:28 +01:00
Julian Winkler
3d9468aa9f implement android.graphics.Path using skia 2024-03-24 22:13:28 +01:00
Julian Winkler
35f26faa90 ImageButton: implement setDrawable() 2024-03-24 22:13:28 +01:00
Julian Winkler
f4a0191b1c implement VectorDrawable, by loading tmp SVG with gdkpixbuf
This won't work for Apps using VectorDrawableCompat
2024-03-24 21:26:38 +01:00
Julian Winkler
26b6da2c9c fix for atl_test_apks/views_widgets_samples_flower_finder.apk
This was broken since the automatic night mode commit. The sdkVersion
configuration for the AssetManager needs to be at least 24, as some
image resources of the APK are only in res/drawable-v24 subfolder
2024-03-24 15:11:38 +01:00
Julian Winkler
494605932c implement more APIs 2024-03-22 21:02:22 +01:00
Julian Winkler
e8dc6e2f0d implement Uri.Builder with hack for content:// URIs 2024-03-22 21:02:22 +01:00
Julian Winkler
e0b3975eb7 implement PackageManager.resolveContentProvider() 2024-03-22 21:02:22 +01:00