File tree Expand file tree Collapse file tree 6 files changed +6
-12
lines changed
Properties/PublishProfiles
UserControls/MultitaskingControl Expand file tree Collapse file tree 6 files changed +6
-12
lines changed Original file line number Diff line number Diff line change @@ -12,6 +12,7 @@ https://go.microsoft.com/fwlink/?LinkID=208121.
12
12
<PublishSingleFile >False</PublishSingleFile >
13
13
<PublishReadyToRun Condition =" '$(Configuration)' == 'Debug'" >False</PublishReadyToRun >
14
14
<PublishReadyToRun Condition =" '$(Configuration)' != 'Debug'" >True</PublishReadyToRun >
15
+ <PublishReadyToRunComposite Condition =" '$(Configuration)' != 'Debug'" >True</PublishReadyToRunComposite >
15
16
<!--
16
17
See https://github.com/microsoft/CsWinRT/issues/373
17
18
<PublishTrimmed>True</PublishTrimmed>
Original file line number Diff line number Diff line change @@ -12,6 +12,7 @@ https://go.microsoft.com/fwlink/?LinkID=208121.
12
12
<PublishSingleFile >False</PublishSingleFile >
13
13
<PublishReadyToRun Condition =" '$(Configuration)' == 'Debug'" >False</PublishReadyToRun >
14
14
<PublishReadyToRun Condition =" '$(Configuration)' != 'Debug'" >True</PublishReadyToRun >
15
+ <PublishReadyToRunComposite Condition =" '$(Configuration)' != 'Debug'" >True</PublishReadyToRunComposite >
15
16
<!--
16
17
See https://github.com/microsoft/CsWinRT/issues/373
17
18
<PublishTrimmed>True</PublishTrimmed>
Original file line number Diff line number Diff line change @@ -12,6 +12,7 @@ https://go.microsoft.com/fwlink/?LinkID=208121.
12
12
<PublishSingleFile >False</PublishSingleFile >
13
13
<PublishReadyToRun Condition =" '$(Configuration)' == 'Debug'" >False</PublishReadyToRun >
14
14
<PublishReadyToRun Condition =" '$(Configuration)' != 'Debug'" >True</PublishReadyToRun >
15
+ <PublishReadyToRunComposite Condition =" '$(Configuration)' != 'Debug'" >True</PublishReadyToRunComposite >
15
16
<!--
16
17
See https://github.com/microsoft/CsWinRT/issues/373
17
18
<PublishTrimmed>True</PublishTrimmed>
Original file line number Diff line number Diff line change @@ -30,10 +30,8 @@ public HorizontalMultitaskingControl()
30
30
tabHoverTimer . Interval = TimeSpan . FromMilliseconds ( 500 ) ;
31
31
tabHoverTimer . Tick += TabHoverSelected ;
32
32
33
- var flowDirectionSetting = new Microsoft . Windows . ApplicationModel . Resources . ResourceManager ( ) . CreateResourceContext ( ) . QualifierValues [ "LayoutDirection" ] ;
34
-
35
33
var appWindowTitleBar = App . GetAppWindow ( App . Window ) . TitleBar ;
36
- double rightPaddingColumnWidth = flowDirectionSetting is "RTL" ? appWindowTitleBar . LeftInset : appWindowTitleBar . RightInset ;
34
+ double rightPaddingColumnWidth = FilePropertiesHelpers . FlowDirectionSettingIsRightToLeft ? appWindowTitleBar . LeftInset : appWindowTitleBar . RightInset ;
37
35
RightPaddingColumn . Width = new GridLength ( rightPaddingColumnWidth >= 0 ? rightPaddingColumnWidth : 0 ) ;
38
36
}
39
37
Original file line number Diff line number Diff line change @@ -173,13 +173,7 @@ public BaseShellPage(CurrentInstanceViewModel instanceViewModel)
173
173
174
174
DisplayFilesystemConsentDialog ( ) ;
175
175
176
- // TODO:
177
- // ResourceContext.GetForCurrentView and ResourceContext.GetForViewIndependentUse do not exist in Windows App SDK
178
- // Use your ResourceManager instance to create a ResourceContext as below.If you already have a ResourceManager instance,
179
- // replace the new instance created below with correct instance.
180
- // Read: https://docs.microsoft.com/en-us/windows/apps/windows-app-sdk/migrate-to-windows-app-sdk/guides/mrtcore
181
- var flowDirectionSetting = new Microsoft . Windows . ApplicationModel . Resources . ResourceManager ( ) . CreateResourceContext ( ) . QualifierValues [ "LayoutDirection" ] ;
182
- if ( flowDirectionSetting == "RTL" )
176
+ if ( FilePropertiesHelpers . FlowDirectionSettingIsRightToLeft )
183
177
FlowDirection = FlowDirection . RightToLeft ;
184
178
185
179
ToolbarViewModel . ToolbarPathItemInvoked += ShellPage_NavigationRequested ;
Original file line number Diff line number Diff line change @@ -66,8 +66,7 @@ public MainPage()
66
66
ViewModel = Ioc . Default . GetRequiredService < MainPageViewModel > ( ) ;
67
67
OngoingTasksViewModel = Ioc . Default . GetRequiredService < OngoingTasksViewModel > ( ) ;
68
68
69
- var flowDirectionSetting = new ResourceManager ( ) . CreateResourceContext ( ) . QualifierValues [ "LayoutDirection" ] ;
70
- if ( flowDirectionSetting == "RTL" )
69
+ if ( FilePropertiesHelpers . FlowDirectionSettingIsRightToLeft )
71
70
FlowDirection = FlowDirection . RightToLeft ;
72
71
73
72
UserSettingsService . OnSettingChangedEvent += UserSettingsService_OnSettingChangedEvent ;
You can’t perform that action at this time.
0 commit comments