xamarin/Xamarin.Forms

[Bug] Overriden resources from a control library are not resolved correctly

开放

#6,871 创建于 2019年7月14日

 (1 条评论) (0 个反应) (0 位负责人)C# (1,926 个派生)batch import
a/binding ⛓a/stylee/6 :clock6:help wantedt/bug :bug:up-for-grabs

仓库指标

星标
 (5,644 个星标)
PR 合并指标
 (30 天内没有已合并 PR)

描述

Description

Overriden resources from a control library are not resolved correctly.

Steps to Reproduce

  1. Create Xamarin.Forms iOS project
  2. Add a library L1 and link it to the two projects (main project and iOS project)
  3. Create resource R1 in the library and add new control/view ControlView with style S1 and resource with key K1.
  4. In app.xaml Resources add MergedDictionaries with reference to resource R1.
  5. In the app.xaml override the resource S1 with new resource S2 with resource key K1.
  6. Create a new ContentView control C1 in library L1 and set its style to StaticResource with key K1.
  7. In MainPage.xaml define two controls ContentView and C1 and set its styles to StaticResource with key K1.

Expected Behavior

MainPage should show the ContentView control with style S2 and C1 control with the style S2 (since S2 overrides S1).

Actual Behavior

MainPage shows the ContentView control with style S2 and C1 control with style S1.

Basic Information

  • Version with issue: XamarinForms 4.1.0.581479
  • Last known good version:
  • IDE: Visual Stydio 2019 for Windows
  • Affected Devices: iOS (I have not tested with other devices.)

Screenshots

Actual

Expected S2 S2

Reproduction Link

App8.zip

贡献者指南