зеркало из https://github.com/DeGsoft/maui-linux.git
* Fix Issue 3386 * Update Xamarin.Forms.Platform.UAP/MasterDetailControl.cs Co-Authored-By: bmacombe <brian@agspectrum.com>
This commit is contained in:
Родитель
be0dc9391b
Коммит
e0bf0bc3e0
|
@ -228,9 +228,10 @@ namespace Xamarin.Forms.Controls.Issues
|
||||||
BackgroundColor = Color.Gray
|
BackgroundColor = Color.Gray
|
||||||
},
|
},
|
||||||
btn
|
btn
|
||||||
}
|
|
||||||
},
|
},
|
||||||
//BackgroundColor = Color.Red
|
BackgroundColor = Color.WhiteSmoke
|
||||||
|
},
|
||||||
|
BackgroundColor = Color.Gray
|
||||||
};
|
};
|
||||||
|
|
||||||
if(initState.HasValue)
|
if(initState.HasValue)
|
||||||
|
|
|
@ -161,18 +161,12 @@ namespace Xamarin.Forms.Platform.UWP
|
||||||
{
|
{
|
||||||
get
|
get
|
||||||
{
|
{
|
||||||
// Use the ActualHeight of the _masterPresenter to automatically adjust for the Master Title
|
double height = ActualHeight;
|
||||||
double height = _masterPresenter?.ActualHeight ?? 0;
|
|
||||||
|
|
||||||
// If there's no content, use the height of the control to make sure the background color expands.
|
|
||||||
if (height == 0)
|
|
||||||
height = ActualHeight;
|
|
||||||
|
|
||||||
double width = 0;
|
double width = 0;
|
||||||
|
|
||||||
// On first load, the _commandBar will still occupy space by the time this is called.
|
// On first load, the _commandBar will still occupy space by the time this is called.
|
||||||
// Check ShouldShowToolbar to make sure the _commandBar will still be there on render.
|
// Check ShouldShowToolbar to make sure the _commandBar will still be there on render.
|
||||||
if (_firstLoad && _commandBar != null && ShouldShowToolbar)
|
if ((_firstLoad || !ShouldShowSplitMode) && _commandBar != null && ShouldShowToolbar)
|
||||||
{
|
{
|
||||||
height -= _commandBar.ActualHeight;
|
height -= _commandBar.ActualHeight;
|
||||||
_firstLoad = false;
|
_firstLoad = false;
|
||||||
|
|
Загрузка…
Ссылка в новой задаче