Bug 22656 - ToolbarItems not rendering correctly on certain combinations
Summary: ToolbarItems not rendering correctly on certain combinations
Alias: None
Product: Forms
Classification: Xamarin
Component: Forms ()
Version: 1.2.3
Hardware: PC Windows
: Normal normal
Target Milestone: ---
Assignee: Seth Rosetter
Depends on:
Reported: 2014-09-04 14:29 UTC by Sergio Paganoni
Modified: 2015-05-29 18:18 UTC (History)
5 users (show)

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

Solution to reproduce the bug (6.39 MB, application/x-zip-compressed)
2014-09-04 14:29 UTC, Sergio Paganoni
bug_page1 (6.28 KB, image/png)
2014-09-04 14:30 UTC, Sergio Paganoni
bug_page2 (7.32 KB, image/png)
2014-09-04 14:30 UTC, Sergio Paganoni
work_page1 (6.33 KB, image/png)
2014-09-04 14:30 UTC, Sergio Paganoni
work_page2 (6.77 KB, image/png)
2014-09-04 14:30 UTC, Sergio Paganoni

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:

Description Sergio Paganoni 2014-09-04 14:29:02 UTC
Created attachment 7925 [details]
Solution to reproduce the bug

Simple scenario:
- Page1 with three toolbar items (see bug_page1.png)
- Page2 with two toolbar items (see work_page2)

Page1 first toolbar item will push Page2 on the stack and should show the two toolbar items (replacing the one added by Page1). This is not the case, when Page2 pop up, the *first* toolbaritem is appended to the three toolbaritems added by Page1 (instead of creating a new clean bar) and the background isn't changed to red as shown in bug_page2.png. 
The expected behavior is that when Page2 pops up, the Background become red and the two toolbar items defined in Page2 class are shown.

When removing one of the three toolbar items in Page1 thinks are working correctly (!!) as shown in work_page1.png and work_page2.png.

I've attached a simple solution to reproduce the problem. Furthermore in the same folder you find the Screenshots folder with the above mentioned pictures.
Comment 1 Sergio Paganoni 2014-09-04 14:30:03 UTC
Created attachment 7926 [details]
Comment 2 Sergio Paganoni 2014-09-04 14:30:22 UTC
Created attachment 7927 [details]
Comment 3 Sergio Paganoni 2014-09-04 14:30:40 UTC
Created attachment 7928 [details]
Comment 4 Sergio Paganoni 2014-09-04 14:30:56 UTC
Created attachment 7929 [details]
Comment 5 Arpit Jha 2014-11-03 06:25:30 UTC
We have checked this issue and able to reproduce it.

We tried to reproduce it with the help of bug description.

Screencast regarding same:

Environment Info:
Microsoft Visual Studio Professional 2013
Version 12.0.30723.00 Update 3
Microsoft .NET Framework
Version 4.5.51641

Installed Version: Professional

Xamarin (8ca7d11db8a6f874c6cd2de6d9ca0f511867ce91)
Visual Studio extension to enable development for Xamarin.iOS and Xamarin.Android.

Xamarin.Android (5474129af31e9d3a86cb7482c7c5c7a30ad315f1)
Visual Studio plugin to enable development for Xamarin.Android.

Xamarin.iOS (209abebbd8f1a292d042420edb45fa5fbd3f017b)
Visual Studio extension to enable development for Xamarin.iOS.
Comment 6 Seth Rosetter 2015-05-29 18:18:58 UTC
This seems to be resolved in current stable (1.4.2). 

Thanks for filing the issue.

- Seth