This repository was archived by the owner on Sep 25, 2024. It is now read-only.
File tree Expand file tree Collapse file tree 3 files changed +5
-9
lines changed
Xamarin.PropertyEditing.Mac/Controls/Custom Expand file tree Collapse file tree 3 files changed +5
-9
lines changed Original file line number Diff line number Diff line change @@ -7,7 +7,6 @@ namespace Xamarin.PropertyEditing.Mac
77{
88 internal class HistoryLayer : ColorEditorLayer
99 {
10- private const float Margin = 3 ;
1110 private const float BorderRadius = 3 ;
1211
1312 public HistoryLayer ( IHostResourceProvider hostResources )
@@ -54,13 +53,13 @@ public override void LayoutSublayers ()
5453 Bounds . Right - Bounds . Height ,
5554 0 ,
5655 Bounds . Height ,
57- Bounds . Height ) . Inset ( Margin , Margin ) ;
56+ Bounds . Height ) ;
5857
5958 this . clip . Frame = new CGRect (
6059 0 ,
6160 0 ,
62- Bounds . Width - Bounds . Height + Margin ,
63- Bounds . Height ) . Inset ( Margin , Margin ) ;
61+ Bounds . Width - Bounds . Height - 3 ,
62+ Bounds . Height ) ;
6463
6564 NSColor cc0 = this . hostResources . GetNamedColor ( NamedResources . Checkerboard0Color ) ;
6665 NSColor cc1 = this . hostResources . GetNamedColor ( NamedResources . Checkerboard1Color ) ;
Original file line number Diff line number Diff line change @@ -86,7 +86,7 @@ public override void Commit (EditorInteraction interaction)
8686 public override void LayoutSublayers ( )
8787 {
8888 base . LayoutSublayers ( ) ;
89- this . colors . Frame = Bounds . Inset ( 2 , 2 ) ;
89+ this . colors . Frame = Bounds ;
9090 this . grip . Frame = new CGRect (
9191 this . grip . Frame . X ,
9292 this . grip . Frame . Y ,
Original file line number Diff line number Diff line change 11using System ;
2- using System . Linq ;
32using AppKit ;
43using CoreAnimation ;
54using CoreGraphics ;
6- using Xamarin . PropertyEditing . Drawing ;
75
86namespace Xamarin . PropertyEditing . Mac
97{
108 class ShadeLayer : ColorEditorLayer
119 {
1210 private const float GripRadius = 4 ;
1311 private const float BorderRadius = 3 ;
14- private const float Margin = 3 ;
1512 private readonly ChannelEditor saturationEditor = new HsbSaturationChannelEditor ( ) ;
1613 private readonly ChannelEditor brightnessEditor = new HsbBrightnessChannelEditor ( ) ;
1714
@@ -68,7 +65,7 @@ public override void LayoutSublayers ()
6865 {
6966 base . LayoutSublayers ( ) ;
7067
71- this . saturationLayer . Frame = Bounds . Inset ( Margin , Margin ) ;
68+ this . saturationLayer . Frame = Bounds ;
7269 this . brightnessLayer . Frame = this . saturationLayer . Bounds ;
7370 this . saturationLayer . StartPoint = new CGPoint ( 0 , .5 ) ;
7471 this . saturationLayer . EndPoint = new CGPoint ( 1 , .5 ) ;
You can’t perform that action at this time.
0 commit comments