74 Commits

Author SHA1 Message Date
affederaffe 1d9a0183eb Bump DBus stack take 2 (#15685)
* Bump DBus stack
- Use new Variant system

* Fix merge issues

* Intentionally break the DBus spec

* Dispose DBus connection and signal watchers

* Bump Tmds,DBus.Protocol

* Dispose DBus objects correctly

* Use PathHandler for DBus objects

* Revert to old initialization

* Bump DBus packages

* Fix global menu

* Add comment about wrapped variants

* Bump Tmds.DBus.SourceGenerator

* Update api baseline

* Bump Tmds.DBus stack

---------

Co-authored-by: Max Katz <maxkatz6@outlook.com>
2024-08-19 06:32:06 +00:00
Max Katz 37ba4ce58e Screens api refactor mobile (#16647)
* Android screen implementation, using Display API (with some fallbacks)

* Browser screen implementation, aditionally add JSObjectPlatformHandle

* iOS screens API implementation with UIScreenPlatformHandle

* Tizen screens implementation, pretty limited but should be better than nothing

* Reduce some API changes to make them more portable in the future

* Update api suppression
2024-08-13 16:22:39 -07:00
Nikita Tsukanov 5b382ae985 Added Compositor.CreateCompositionVisualSnapshot API (#16599)
* Added Compositor.CreateCompositionVisualSnapshot API

* Hurr durr api compat in [Unstable] interface

---------

Co-authored-by: Max Katz <maxkatz6@outlook.com>
2024-08-05 15:25:18 -07:00
Max Katz d3f234bad5 Reset API validation baseline (#16470) 2024-07-25 18:16:14 -07:00
Max Katz 05ac6d2f1d Screens API refactor (#16295)
* Draft new API

* Push reusable ScreensBaseImpl implementation

* Fix tests and stubs

* Update ScreensPage sample to work on mobile + show new APIs

* Reimplement Windows ScreensImpl, reuse existing screens in other places of backend, use Microsoft.Windows.CsWin32 for interop

* Make X11 project buildable, don't utilize new APIs yet

* Reimplement macOS Screens API, differenciate screens by CGDirectDisplayID

* Fix build

* Adjust breaking changes file (none affect users)

* Fix missing macOS Screen.DisplayName

* Add more tests + fix screen removal

* Add screens integration tests

* Use hash set with comparer when removing screens

* Make screenimpl safer on macOS as per review

* Replace UnmanagedCallersOnly usage with source generated EnumDisplayMonitors

* Remove unused dllimport

* Only implement GetHashCode and Equals on PlatformScreen subclass, without changing base Screen
2024-07-16 15:48:18 -07:00
Nikita Tsukanov 1639aabd3c Revert "Reapply (#15568) + Updates (#16129)" (#16175)
This reverts commit 9c955d3b3d.
2024-06-30 18:04:19 +03:00
Jumar Macato 9c955d3b3d Reapply (#15568) + Updates (#16129)
* Reapply "Bump DBus stack (#15568)" (#15656)

This reverts commit e787bb4e64.

* Bump dbus libs versions again

* Fix PathHandler usages

* Add suppression for FreeDesktop lib

---------

Co-authored-by: Max Katz <maxkatz6@outlook.com>
2024-06-26 11:19:13 +08:00
Max Katz 6938183319 Improve DevTools previewer of setter values by including all value priorities (#13802)
* Replace "Active Styles" dev tools analysis with "Active Value Frames"

* Remove old diagnostic methods from public API (breaking change)

* Show full style selectors

* Avoid unnecessary value setters by checking if color was actually changed

* Run UpdateStyles from the dispatcher to fix flickering issue

* Fix build
2024-05-09 22:32:38 +00:00
Wiesław Šoltés f7feaba5a0 Add Close and ClearAll api for INotificationManager and IManagedNotificationManager (#15628)
* Add Close and ClearAll api for INotificationManager

* Remove notification card item on close

* Make _notificationCards readonly

* Clear _notificationCards when detached from visual tree

* Update Avalonia.nupkg.xml

* Use cancellationToken = default instead of null

* Rename ClearAll to CloseAll for consistency with Close method naming

* Remove cancellationToken param from Show method for better compatibility

* Update Avalonia.nupkg.xml

---------

Co-authored-by: Jumar Macato <16554748+jmacato@users.noreply.github.com>
2024-05-07 08:43:34 +00:00
Max Katz 7816f11858 Browser software renderer and some refactoring allowing multiple AvaloniaView instances (#15207)
* Update .NET runtime TypeScript definitions

* Get splash screen by classname instead of ID

* Minimize css usage

* Move insets css properties to JS file

* Refactor browser surface handling, re-enable software renderer, allow fallback render modes

* Extract render timer from the surface, try to reuse compositor instance between avalonia views

* ControlCatalog: Make it possible to set some browser properties (like render mode) from URI arguments

* Rename AppBundle folder to wwwroot

* Extract ITextInputMethodImpl into a BrowserTopLevelImpl

* Extract input into BrowserInputHandler

* Make default surface size 1,1 to match other backends

* Reformat code that I touched (for the most part)

* Why this method even was in public API
2024-04-05 21:01:32 -07:00
MakesYT 299c16da55 Enhancement Allow unload AssemblyLoadContext which contains Avalonia content #13935 (#13974)
* Try fix #13935

* Fix

* Fix

* add sample

* Fix

* try load Style by reflection

* try

* Fixed an error when registering properties when uninstalling assemblies

* Allowed to delete the IAssemblyDescriptorResolver StandardAssetLoader _assemblyNameCache

* Resolving merge conflicts

* Fix

* Add exegesis

* optimize

* fix

* Resolving merge conflicts

* nuke
2024-04-05 16:28:28 -07:00
Max Katz 326ef7c9fd Add .NET 8 target (Avalonia 11.1) (#14535)
* Add .NET 8 target to packable projects

* Update test projects

* Update sample projects to target .NET 8

* Update main Avalonia package to target .NET 8 as well

* Remove MSBuildEnableWorkloadResolver hack and some minor change

* Use net8.0 in nuke build as well

* Pin 8.0.0 SDK

* Adjust API validation

* Pin a valid version

* Remove net461 target from Avalonia package

* Remove unused net6.0 target from Avalonia.Designer.HostApp

* Adjust API diff

* Update ControlCatalog.Android.csproj

* Remove MSBuildEnableWorkloadResolver

* Fix Browser issues on .NET 8

* Fix .NET 8 error

* Fix merge conflicts

* Replace explicit TFMs in .csproj files with a centralized registry

* Fix merge conflict

* Fix AvsLegacyWindowsTargetFrameworks and add hacks for the tests

* Update XCode project CommandLineArgument

---------

Co-authored-by: Nikita Tsukanov <keks9n@gmail.com>
2024-03-05 13:37:26 -08:00
Julien Lebosquain 0399137b2d Made NamespaceInfo internal (#14793) 2024-03-02 23:13:09 +00:00
Nikita Tsukanov f3f26eb113 Introduced a way to lease the underlying platform graphics context from Skia context (#14652)
* Introduced a way to lease the underlying platform graphics context from Skia context

* API suppression
2024-02-19 21:47:47 -08:00
Nikita Tsukanov 8329efddd3 Fixes relative brush mapping mode (#14598)
* Fixed relative mapping mode for brushes (skia only, pending radial)

* Implemented separate RadiusX/RadiusY with proper mapping modes for RadialGradientBrush

* tests for conic brush

* Added tests for geometry drawing

* Updated DrawingBrush test image since it now matches WPF

* Update obsolete property usage

* Fixed D2D, updated radial test with D2D results that actually match WPF ones

* Fixed RadiusX/Y for radial gradients with non-centered origin

* Updated obsolete property usage

* Code cleanup

* Typo

* ApiDiff suppression

* Removed files for skipped test

* More info in obsoletion warning

* clarify

---------

Co-authored-by: Jumar Macato <16554748+jmacato@users.noreply.github.com>
2024-02-13 12:02:42 +00:00
Tim 73f7fd1d3e Remove Console support in DevTools (#13920)
* Remove Console support in DevTools

* Adjust breaking changes

* And remove Microsoft.CodeAnalysis

---------

Co-authored-by: Max Katz <maxkatz6@outlook.com>
2023-12-13 00:32:17 +00:00
Max Katz 60c11167f8 Add default template to the ContentControl, remove theme specific templates (#11365)
* Move ContentPresenter template to the property default value

* Fix some unit tests

* Fix more tests

* Fix more tests

* Update api rules
2023-11-07 14:48:24 +00:00
Julien Lebosquain c40b627403 Fix ref assembly generator making nested types public (#13513) 2023-11-06 23:43:50 +00:00
Julien Lebosquain d968d7bf2d Update XamlX (#13158)
* Update XamlX, with Avalonia changes

* Made XamlX internal in Designer.HostApp
2023-10-06 17:21:08 +00:00
Max Katz 081803b292 Add api change suppression for ImportCompleted 2023-07-13 17:20:23 -04:00
Max Katz 54158b475e Fix separators issue in ApiDiffValidatiton too 2023-07-11 23:09:49 -04:00
Max Katz bd8628bfef Revert "Add suppression for removed generated NamespaceInfo types"
This reverts commit 4419ef7d47.
2023-07-10 20:22:47 -04:00
Max Katz 98e5f74f4e Fix xml files generation 2023-07-10 20:22:40 -04:00
Julien Lebosquain 4419ef7d47 Add suppression for removed generated NamespaceInfo types 2023-07-10 23:10:55 +02:00