Skip to content
This repository has been archived by the owner on May 1, 2024. It is now read-only.

[Bug] TabbedPage Child Title Binding with OnPropertyChanged #13679

Open
LittleCornerDev opened this issue Feb 5, 2021 · 0 comments
Open

[Bug] TabbedPage Child Title Binding with OnPropertyChanged #13679

LittleCornerDev opened this issue Feb 5, 2021 · 0 comments

Comments

@LittleCornerDev
Copy link

Description

When binding a view model property (whose value is set elsewhere) as the page title in a TabbedPage child/tab, the displayed value doesn't update after calling OnPropertyChanged() for the property.

Steps to Reproduce

  1. Clone Bug Repro on GitHub
  2. Deploy the project (either Android or iOS). It has two tabs, the first with a count using a setter, the second with a count using OnPropertyChanged
  3. Click on "Increment Count" button on page to increment the counts.
  4. Alerts will show both count values have incremented.
  5. Tab title bound to count with a setter updates. Tab title bound to count with no setter (using OnPropertyChanged instead) does NOT update.

Expected Behavior

OnPropertyChanged should trigger bound property to re-run its getter and update display in view.

Actual Behavior

OnPropertyChanged seems to trigger bound property to re-run its getter (value in alert is correct) but the displayed text is not updated.

Basic Information

  • Version with issue: 5.0.0.1931
  • Last known good version: unknown
  • Platform Target Frameworks:
    • iOS: 14.3
    • Android: 28 / 9.0
    • UWP: n/a
  • Android Support Library / AndroidX Version:
  • NuGet Packages:
  • Affected Devices:

Environment

Show/Hide Visual Studio info
=== Visual Studio Community 2019 for Mac ===

Version 8.8.7 (build 18)
Installation UUID: 78938978-555e-4ad5-a3d6-cf254f5e62b7
	GTK+ 2.24.23 (Raleigh theme)
	Xamarin.Mac 6.18.0.23 (d16-6 / 088c73638)

	Package version: 612000113

=== Mono Framework MDK ===

Runtime:
	Mono 6.12.0.113 (2020-02/4fdfb5b1fd5) (64-bit)
	Package version: 612000113

=== Roslyn (Language Service) ===

3.8.0-5.20519.18+4c195c3ac1974edcefa76774d7a59a2350ec55fa

=== NuGet ===

Version: 5.8.0.6860

=== .NET Core SDK ===

SDK: /usr/local/share/dotnet/sdk/5.0.102/Sdks
SDK Versions:
	5.0.102
	5.0.101
	5.0.100
	3.1.405
	3.1.404
	3.1.403
	3.1.402
	3.1.401
	3.1.302
	3.1.301
	3.1.300
	3.1.202
	3.1.200
	3.1.102
	3.1.101
	3.1.100
	3.0.101
	3.0.100
	2.2.300
	2.2.103
	2.1.505
	2.1.302
MSBuild SDKs: /Applications/Visual Studio.app/Contents/Resources/lib/monodevelop/bin/MSBuild/Current/bin/Sdks

=== .NET Core Runtime ===

Runtime: /usr/local/share/dotnet/dotnet
Runtime Versions:
	5.0.2
	5.0.1
	5.0.0
	3.1.11
	3.1.10
	3.1.9
	3.1.8
	3.1.7
	3.1.6
	3.1.5
	3.1.4
	3.1.2
	3.1.1
	3.1.0
	3.0.1
	3.0.0
	2.2.5
	2.2.1
	2.1.23
	2.1.22
	2.1.21
	2.1.20
	2.1.19
	2.1.18
	2.1.17
	2.1.16
	2.1.15
	2.1.14
	2.1.13
	2.1.9
	2.1.2

=== .NET Core 3.1 SDK ===

SDK: 3.1.405

=== Xamarin.Profiler ===

Version: 1.6.12.29
Location: /Applications/Xamarin Profiler.app/Contents/MacOS/Xamarin Profiler

=== Updater ===

Version: 11

=== Apple Developer Tools ===

Xcode 12.4 (17801)
Build 12D4e

=== Xamarin.Mac ===

Version: 7.2.0.3 (Visual Studio Community)
Hash: c51fabee8
Branch: xcode12.3
Build date: 2020-12-10 21:05:04-0500

=== Xamarin.iOS ===

Version: 14.8.0.3 (Visual Studio Community)
Hash: c51fabee8
Branch: xcode12.3
Build date: 2020-12-10 21:05:05-0500

=== Xamarin.Android ===

Version: 11.1.0.26 (Visual Studio Community)
Commit: xamarin-android/d16-8/a36ce73
Android SDK: /Users/*/Library/Android/sdk
	Supported Android versions:
		None installed

SDK Tools Version: 26.1.1
SDK Platform Tools Version: 30.0.5
SDK Build Tools Version: 30.0.3

Build Information: 
Mono: 5e9cb6d
Java.Interop: xamarin/java.interop/d16-8@79d9533
ProGuard: Guardsquare/proguard/proguard6.2.2@ebe9000
SQLite: xamarin/sqlite/3.32.1@1a3276b
Xamarin.Android Tools: xamarin/xamarin-android-tools/d16-8@2fb1cbc

=== Microsoft OpenJDK for Mobile ===

Java SDK: /Users/*/Library/Developer/Xamarin/jdk/microsoft_dist_openjdk_1.8.0.25
1.8.0-25
Android Designer EPL code available here:
https://github.com/xamarin/AndroidDesigner.EPL

=== Android SDK Manager ===

Version: 16.8.0.32
Hash: 01a7774
Branch: remotes/origin/d16-8
Build date: 2021-01-14 00:34:58 UTC

=== Android Device Manager ===

Version: 16.8.0.46
Hash: 0a81419
Branch: remotes/origin/d16-8
Build date: 2021-01-14 00:35:22 UTC

=== Xamarin Designer ===

Version: 16.8.0.510
Hash: 44e3f3ce9
Branch: remotes/origin/d16-8
Build date: 2020-12-10 00:06:14 UTC

=== Build Information ===

Release ID: 808070018
Git revision: 0f6def3c0ff5f9cee230e65718561cb41c8eedc0
Build date: 2021-01-29 08:24:09-05
Build branch: release-8.8
Xamarin extensions: 0f6def3c0ff5f9cee230e65718561cb41c8eedc0

=== Operating System ===

Mac OS X 10.15.7
Darwin 19.6.0 Darwin Kernel Version 19.6.0
    Tue Jan 12 22:13:05 PST 2021
    root:xnu-6153.141.16~1/RELEASE_X86_64 x86_64

=== Enabled user installed extensions ===

Code Coverage 1.0


Build Logs

Screenshots

TabbedPageBinding0
TabbedPageBinding1

Reproduction Link

Bug Repro on GitHub

Workaround

Explicitly using a setter, instead of relying on OnPropertyChanged to re-load the getter.

@LittleCornerDev LittleCornerDev added s/unverified New report that has yet to be verified t/bug 🐛 labels Feb 5, 2021
@jsuarezruiz jsuarezruiz added p/Android p/iOS 🍎 and removed s/unverified New report that has yet to be verified labels Feb 12, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

2 participants