Я присваиваю кнопке эффект ColorAnimation в соответствии с темой, выбранной пользователем. Проблема в том, что здесь я не могу просто использовать DynamicResource, потому что ColorAnimation необходимо заморозить, чтобы использовать в раскадровках.
Поэтому я добавил свойство зависимости с именем
Код: Выделить всё
SelectedTheme
As a result, when the mouse enters control and the
Код: Выделить всё
SelectedTheme
I used nested trigger and event trigger as below, but it didn't work. Is there any situation where I can combine these triggers?
Or can you offer an alternative solution for the dynamic resource situation in ColorAnimation?
Код: Выделить всё
Источник: https://stackoverflow.com/questions/781 ... her-in-wpf