瀏覽代碼

Android and browser internals

Max Katz 2 年之前
父節點
當前提交
d27936af67

+ 2 - 2
src/Android/Avalonia.Android/AndroidInputMethod.cs

@@ -32,7 +32,7 @@ namespace Avalonia.Android
        ActionPrevious = 0x00000007,
     }
 
-    class AndroidInputMethod<TView> : ITextInputMethodImpl, IAndroidInputMethod
+    internal class AndroidInputMethod<TView> : ITextInputMethodImpl, IAndroidInputMethod
         where TView : View, IInitEditorInfo
     {
         private readonly TView _host;
@@ -167,7 +167,7 @@ namespace Avalonia.Android
         }
     }
 
-    public readonly record struct ComposingRegion
+    internal readonly record struct ComposingRegion
     {
         private readonly int _start = -1;
         private readonly int _end = -1;

+ 1 - 0
src/Android/Avalonia.Android/Avalonia.Android.csproj

@@ -5,6 +5,7 @@
     <AllowUnsafeBlocks>true</AllowUnsafeBlocks>
     <MSBuildEnableWorkloadResolver>true</MSBuildEnableWorkloadResolver>
     <DebugType>portable</DebugType>
+    <AndroidResgenNamespace>Avalonia.Android.Internal</AndroidResgenNamespace>
   </PropertyGroup>
   <ItemGroup>
     <ProjectReference Include="..\..\..\packages\Avalonia\Avalonia.csproj" />

+ 1 - 1
src/Android/Avalonia.Android/Platform/Input/AndroidKeyboardDevice.cs

@@ -5,7 +5,7 @@ using Avalonia.Input;
 
 namespace Avalonia.Android.Platform.Input
 {
-    public class AndroidKeyboardDevice : KeyboardDevice, IKeyboardDevice {
+    internal class AndroidKeyboardDevice : KeyboardDevice, IKeyboardDevice {
     private static readonly Dictionary<Keycode, Key> KeyDic = new Dictionary<Keycode, Key>
      {
          //   { Keycode.Cancel?, Key.Cancel },

+ 1 - 1
src/Android/Avalonia.Android/Platform/SkiaPlatform/InvalidationAwareSurfaceView.cs

@@ -10,7 +10,7 @@ using Avalonia.Platform;
 
 namespace Avalonia.Android
 {
-    public abstract class InvalidationAwareSurfaceView : SurfaceView, ISurfaceHolderCallback, IPlatformNativeSurfaceHandle
+    internal abstract class InvalidationAwareSurfaceView : SurfaceView, ISurfaceHolderCallback, IPlatformNativeSurfaceHandle
     {
         bool _invalidateQueued;
         readonly object _lock = new object();

+ 2 - 2
src/Android/Avalonia.Android/PlatformIconLoader.cs

@@ -3,7 +3,7 @@ using Avalonia.Platform;
 
 namespace Avalonia.Android
 {
-    class PlatformIconLoader : IPlatformIconLoader
+    internal class PlatformIconLoader : IPlatformIconLoader
     {
         public IWindowIconImpl LoadIcon(IBitmapImpl bitmap)
         {
@@ -29,7 +29,7 @@ namespace Avalonia.Android
     }
 
     // Stores the icon created as a stream to support saving even though an icon is never shown
-    public class FakeIcon : IWindowIconImpl
+    internal class FakeIcon : IWindowIconImpl
     {
         private Stream stream = new MemoryStream();
 

+ 3 - 3
src/Android/Avalonia.Android/Stubs.cs

@@ -4,7 +4,7 @@ using Avalonia.Platform;
 
 namespace Avalonia.Android
 {
-    class WindowingPlatformStub : IWindowingPlatform
+    internal class WindowingPlatformStub : IWindowingPlatform
     {
         public IWindowImpl CreateWindow() => throw new NotSupportedException();
 
@@ -13,7 +13,7 @@ namespace Avalonia.Android
         public ITrayIconImpl CreateTrayIcon() => null;
     }
 
-    class PlatformIconLoaderStub : IPlatformIconLoader
+    internal class PlatformIconLoaderStub : IPlatformIconLoader
     {
         public IWindowIconImpl LoadIcon(IBitmapImpl bitmap)
         {
@@ -38,7 +38,7 @@ namespace Avalonia.Android
         }
     }
 
-    public class IconStub : IWindowIconImpl
+    internal class IconStub : IWindowIconImpl
     {
         private readonly MemoryStream _ms;
 

+ 1 - 1
src/Browser/Avalonia.Browser/Skia/BrowserSkiaGpu.cs

@@ -6,7 +6,7 @@ using Avalonia.Reactive;
 
 namespace Avalonia.Browser.Skia
 {
-    public class BrowserSkiaGpu : ISkiaGpu
+    internal class BrowserSkiaGpu : ISkiaGpu
     {
         public ISkiaGpuRenderTarget? TryCreateRenderTarget(IEnumerable<object> surfaces)
         {