Bug 32959 - when navigated to Masterdetailpage icon not rendering
Summary: when navigated to Masterdetailpage icon not rendering
Status: RESOLVED ANSWERED
Alias: None
Product: Forms
Classification: Xamarin
Component: Forms ()
Version: 1.5.0
Hardware: PC Windows
: Normal normal
Target Milestone: ---
Assignee: Bugzilla
URL:
Depends on:
Blocks:
 
Reported: 2015-08-11 10:48 UTC by stephen.machwirth
Modified: 2015-10-14 01:22 UTC (History)
5 users (show)

Tags:
Is this bug a regression?: ---
Last known good build:

Notice (2018-05-24): bugzilla.xamarin.com is now in read-only mode.

Please join us on Visual Studio Developer Community and in the Xamarin and Mono organizations on GitHub to continue tracking issues. Bugzilla will remain available for reference in read-only mode. We will continue to work on open Bugzilla bugs, copy them to the new locations as needed for follow-up, and add the new items under Related Links.

Our sincere thanks to everyone who has contributed on this bug tracker over the years. Thanks also for your understanding as we make these adjustments and improvements for the future.


Please create a new report on Developer Community or GitHub with your current version information, steps to reproduce, and relevant error messages or log files if you are hitting an issue that looks similar to this resolved bug and you do not yet see a matching new report.

Related Links:
Status:
RESOLVED ANSWERED

Description stephen.machwirth 2015-08-11 10:48:22 UTC
MD VIew

<?xml version="1.0" encoding="utf-8" ?>
<MasterDetailPage xmlns="http://xamarin.com/schemas/2014/forms"
             xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml"
             x:Class=""
             Title="Home" Icon="menu_icon.png">
  <MasterDetailPage.Detail>
    <ContentPage Title="Load" Icon="icon_menu.png">
      <Grid RowSpacing="0" BackgroundColor="#e8eddf">
        <Grid.ColumnDefinitions>
          <ColumnDefinition Width="*" />
          <ColumnDefinition Width="*" />
        </Grid.ColumnDefinitions>
        <Grid.RowDefinitions>
          <RowDefinition Height="*" />
          <RowDefinition Height="*" />
          <RowDefinition Height="*" />
          <RowDefinition Height="*" />
        </Grid.RowDefinitions>
        
      </Grid>
    </ContentPage>
  </MasterDetailPage.Detail>
</MasterDetailPage>

-------------------------------------------------------------
MD page.cs
namespace Project.Views
{
    public partial class MainPageView : MasterDetailPage
    {
        public MainPageView() 
        {
            InitializeComponent();
            Master = new MenuView();
            Detail.BindingContext = App.Locator.Detail;
        }
    }
}


-------------------------------------------------------------
menuview

<?xml version="1.0" encoding="utf-8" ?>
<ContentPage xmlns="http://xamarin.com/schemas/2014/forms"
             xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml"
             x:Class="PROJECT.Views.MenuView"
             Title="Menu" Icon="icon_menu.png">
  <StackLayout>
    <Button Text="Uitloggen" />
  </StackLayout>
</ContentPage>

when setting the icon and text manually I don't see the icon in iOS. I navigate to this screen by the pushmodalasync method. 
I'm displaying the MasterDetailPage within a NavigationPage. The title of the MasterDetailPage does display, however the icon is not visible on iOS, the icon is visible when running on a android device.
Comment 1 Parmendra Kumar 2015-08-21 08:20:35 UTC
I have tried to reproduce this issue with provided sample code in bug description and I am not able to reproduce this issue.
I am getting error in "App.Locator.Detail;"

Screencast: http://www.screencast.com/t/TBP2GN4Ff

Sample: https://www.dropbox.com/s/xosc9sdt28bpm0d/App371.zip?dl=0

Please follow the screencast and sample project and let me know I have missed anything.

Could you please provide us a sample project? so that I can reproduce this issue at my end.

Thanks.
Comment 2 stephen.machwirth 2015-08-21 08:29:04 UTC
Remove the bindingcontext all together this isn't necessary, but be sure of the adding of the icon_menu.jpg, this is a image of a hamburger menu.
Comment 3 Parmendra Kumar 2015-08-21 11:08:58 UTC
Thanks @stephen,

I have rechecked this issue and observed that icon not rendering.

Please follow the screencast and sample project and let me know if you getting same behavior or I have missed anything.

Screencast: http://www.screencast.com/t/fQZKW4eoM52n

Sample: https://www.dropbox.com/s/8j06jetb95nznkh/App372.zip?dl=0


Thanks..!
Comment 4 stephen.machwirth 2015-08-24 03:09:16 UTC
Correct the icon isn't displaying
Comment 5 Parmendra Kumar 2015-08-24 05:37:02 UTC
As per comment #4, confirming this issue.
Comment 6 Jason Smith [MSFT] 2015-10-14 01:22:01 UTC
This is the current expected behavior. The icon only shows if you have a NavigationPage.