/foundation/arkui/ace_engine/frameworks/bridge/declarative_frontend/ark_theme/theme_apply/ |
H A D | js_button_theme.h | 28 JSButtonTheme::buttonRole = role; in ApplyTheme() member in OHOS::Ace::Framework::JSButtonTheme::JSButtonTheme 34 JSButtonTheme::buttonRole = role; in ApplyTheme() member in OHOS::Ace::Framework::JSButtonTheme::JSButtonTheme 44 inline static ButtonRole buttonRole = ButtonRole::NORMAL; member in OHOS::Ace::Framework::JSButtonTheme 73 if (JSButtonTheme::buttonRole == ButtonRole::ERROR) { in FontColor() 92 if (JSButtonTheme::buttonRole == ButtonRole::ERROR) { in BackgroundColor()
|
/foundation/arkui/ace_engine/frameworks/core/components_ng/pattern/button/ |
H A D | button_model_ng.cpp | 86 ButtonRole buttonRole = layoutProperty->GetButtonRole().value_or(ButtonRole::NORMAL); in SetButtonStyle() local 87 auto bgColor = buttonTheme->GetBgColor(buttonStyle.value(), buttonRole); in SetButtonStyle() 88 auto textColor = buttonTheme->GetTextColor(buttonStyle.value(), buttonRole); in SetButtonStyle() 94 void ButtonModelNG::SetRole(const std::optional<ButtonRole>& buttonRole) in SetRole() argument 96 if (buttonRole.has_value()) { in SetRole() 97 ACE_UPDATE_LAYOUT_PROPERTY(ButtonLayoutProperty, ButtonRole, buttonRole.value()); in SetRole() 106 auto bgColor = buttonTheme->GetBgColor(buttonStyleMode, buttonRole.value()); in SetRole() 107 auto textColor = buttonTheme->GetTextColor(buttonStyleMode, buttonRole.value()); in SetRole() 130 void ButtonModelNG::SetRole(FrameNode* frameNode, const std::optional<ButtonRole>& buttonRole) in SetRole() argument 132 if (buttonRole in SetRole() 158 ButtonRole buttonRole = layoutProperty->GetButtonRole().value_or(ButtonRole::NORMAL); SetButtonStyle() local 612 ApplyTheme(FrameNode* frameNode, ButtonStyleMode buttonStyle, ButtonRole buttonRole) ApplyTheme() argument [all...] |
H A D | button_model_ng.h | 59 void SetRole(const std::optional<ButtonRole>& buttonRole) override; 82 static void SetRole(FrameNode* frameNode, const std::optional<ButtonRole>& buttonRole); 88 static void ApplyTheme(FrameNode* frameNode, ButtonStyleMode buttonStyle, ButtonRole buttonRole);
|
H A D | button_pattern.cpp | 152 ButtonRole buttonRole = layoutProperty->GetButtonRole().value_or(ButtonRole::NORMAL); in UpdateTextStyle() local 153 Color fontColor = buttonTheme->GetTextColor(buttonStyle, buttonRole); in UpdateTextStyle() 419 ButtonRole buttonRole = layoutProperty->GetButtonRole().value_or(ButtonRole::NORMAL); in HandleBackgroundColor() local 427 renderContext->UpdateBackgroundColor(buttonTheme->GetBgColor(buttonStyle, buttonRole)); in HandleBackgroundColor() 429 themeBgColor_ = buttonTheme->GetBgColor(buttonStyle, buttonRole); in HandleBackgroundColor() 430 themeTextColor_ = buttonTheme->GetTextColor(buttonStyle, buttonRole); in HandleBackgroundColor() 574 ButtonRole buttonRole = buttonLayoutProperty->GetButtonRole().value_or(ButtonRole::NORMAL); in OnColorConfigurationUpdate() local 578 auto color = buttonTheme->GetBgColor(buttonStyle, buttonRole); in OnColorConfigurationUpdate() 586 textLayoutProperty->UpdateTextColor(buttonTheme->GetTextColor(buttonStyle, buttonRole)); in OnColorConfigurationUpdate()
|
H A D | button_request_data.h | 34 std::optional<ButtonRole> buttonRole; member
|
H A D | button_model.h | 60 virtual void SetRole(const std::optional<ButtonRole>& buttonRole) {} in SetRole() argument
|
H A D | button_pattern.h | 230 static std::string ConvertButtonRoleToString(ButtonRole buttonRole) in ConvertButtonRoleToString() argument 233 switch (buttonRole) { in ConvertButtonRoleToString()
|
/foundation/arkui/ace_engine/frameworks/core/components/button/ |
H A D | button_theme.h | 358 Color GetBgColor(ButtonStyleMode buttonStyle, ButtonRole buttonRole) const in GetBgColor() 360 auto bgColorMapByRole_ = bgColorMap_.find(buttonRole); in GetBgColor() 371 const Color& GetTextColor(ButtonStyleMode buttonStyle, ButtonRole buttonRole) const in GetTextColor() 373 auto roleResult = textColorByRoleMap_.find(buttonRole); in GetTextColor() 376 if (buttonRole == ButtonRole::ERROR) { in GetTextColor()
|
/foundation/arkui/ace_engine/frameworks/core/interfaces/native/node/ |
H A D | button_modifier.cpp | 525 void SetButtonRole(ArkUINodeHandle node, ArkUI_Uint32 buttonRole) in SetButtonRole() argument 530 if (buttonRole >= static_cast<uint32_t>(ButtonRole::NORMAL) && buttonRole <= in SetButtonRole() 532 role = static_cast<ButtonRole>(buttonRole); in SetButtonRole() 603 void SetButtonOptions(ArkUINodeHandle node, ArkUI_Uint32 buttonStyle, ArkUI_Uint32 buttonRole) in SetButtonOptions() argument 613 if (buttonRole >= static_cast<uint32_t>(ButtonRole::NORMAL) && buttonRole <= in SetButtonOptions() 615 role = static_cast<ButtonRole>(buttonRole); in SetButtonOptions()
|
/foundation/arkui/ace_engine/frameworks/bridge/declarative_frontend/jsview/ |
H A D | js_button.cpp | 234 auto buttonRole = static_cast<ButtonRole>(value); in SetRole() local 235 if (!JSButtonTheme::ApplyTheme(buttonRole, isLabelButton_)) { in SetRole() 236 ButtonModel::GetInstance()->SetRole(buttonRole); in SetRole() 405 auto buttonRole = para.buttonRole.value_or(ButtonRole::NORMAL); in CreateWithLabel() local 407 JSButtonTheme::ApplyTheme(buttonRole, buttonStyleMode, isLabelButton_); in CreateWithLabel() 416 auto buttonRole = para.buttonRole.value_or(ButtonRole::NORMAL); in CreateWithChild() local 418 JSButtonTheme::ApplyTheme(buttonRole, buttonStyleMode, isLabelButton_); in CreateWithChild() 740 param.buttonRole in ParseButtonRole() [all...] |
/foundation/arkui/ace_engine/frameworks/bridge/declarative_frontend/engine/jsi/nativeModule/ |
H A D | arkts_native_button_bridge.cpp | 145 uint32_t buttonRole = DEFAULT_ROLE; in SetOptions() local 147 buttonRole = roleArg->Uint32Value(vm); in SetOptions() 153 GetArkUINodeModifiers()->getButtonModifier()->setButtonRole(nativeNode, buttonRole); in SetOptions() 154 GetArkUINodeModifiers()->getButtonModifier()->setButtonOptions(nativeNode, buttonStyle, buttonRole); in SetOptions() 669 uint32_t buttonRole = buttonRoleArgs->Uint32Value(vm); in SetButtonRole() local 670 GetArkUINodeModifiers()->getButtonModifier()->setButtonRole(nativeNode, buttonRole); in SetButtonRole()
|
/foundation/arkui/ace_engine/test/unittest/core/pattern/button/ |
H A D | button_test_ng.cpp | 108 std::optional<ButtonRole> buttonRole = std::nullopt; member 280 if (testProperty.buttonRole.has_value()) { in CreateLabelButtonParagraphByRoundedRect() 281 buttonModelNG.SetRole(testProperty.buttonRole.value()); in CreateLabelButtonParagraphByRoundedRect() 325 if (testProperty.buttonRole.has_value()) { in CreateLabelButtonParagraph() 326 buttonModelNG.SetRole(testProperty.buttonRole.value()); in CreateLabelButtonParagraph() 1358 testProperty.buttonRole = ButtonRole::NORMAL; in HWTEST_F() 1409 testProperty.buttonRole = ButtonRole::ERROR; in HWTEST_F()
|
H A D | button_extend_test_ng.cpp | 91 std::optional<ButtonRole> buttonRole = std::nullopt; member
|
H A D | button_content_modifier_test_ng.cpp | 86 std::optional<ButtonRole> buttonRole = std::nullopt; member 247 if (testProperty.buttonRole.has_value()) { in CreateLabelButtonParagraph() 248 buttonModelNG.SetRole(testProperty.buttonRole.value()); in CreateLabelButtonParagraph()
|
/foundation/arkui/ace_engine/frameworks/core/components_ng/pattern/calendar_picker/ |
H A D | calendar_dialog_view.cpp | 666 ButtonRole buttonRole = buttonLayoutProperty->GetButtonRole().value_or(ButtonRole::NORMAL); in UpdateButtonStyleAndRole() local 667 auto bgColor = buttonTheme->GetBgColor(buttonInfos[index].buttonStyle.value(), buttonRole); in UpdateButtonStyleAndRole() 668 auto textColor = buttonTheme->GetTextColor(buttonInfos[index].buttonStyle.value(), buttonRole); in UpdateButtonStyleAndRole()
|
/foundation/arkui/ace_engine/frameworks/core/components_ng/pattern/time_picker/ |
H A D | timepicker_dialog_view.cpp | 874 ButtonRole buttonRole = buttonLayoutProperty->GetButtonRole().value_or(ButtonRole::NORMAL); 875 auto bgColor = buttonTheme->GetBgColor(buttonInfos[index].buttonStyle.value(), buttonRole); 876 auto textColor = buttonTheme->GetTextColor(buttonInfos[index].buttonStyle.value(), buttonRole);
|
/foundation/arkui/ace_engine/frameworks/core/components_ng/pattern/text_picker/ |
H A D | textpicker_dialog_view.cpp | 785 ButtonRole buttonRole = buttonLayoutProperty->GetButtonRole().value_or(ButtonRole::NORMAL); 786 auto bgColor = buttonTheme->GetBgColor(buttonInfos[index].buttonStyle.value(), buttonRole); 787 auto textColor = buttonTheme->GetTextColor(buttonInfos[index].buttonStyle.value(), buttonRole);
|
/foundation/arkui/ace_engine/frameworks/core/components_ng/pattern/picker/ |
H A D | datepicker_dialog_view.cpp | 942 ButtonRole buttonRole = buttonLayoutProperty->GetButtonRole().value_or(ButtonRole::NORMAL); 943 auto bgColor = buttonTheme->GetBgColor(buttonInfos[index].buttonStyle.value(), buttonRole); 944 auto textColor = buttonTheme->GetTextColor(buttonInfos[index].buttonStyle.value(), buttonRole);
|
/foundation/arkui/ace_engine/frameworks/core/interfaces/cjui/ |
H A D | cjui_api.h | 703 void (*setButtonRole)(ArkUINodeHandle node, ArkUI_Uint32 buttonRole);
712 void (*setButtonOptions)(ArkUINodeHandle node, ArkUI_Uint32 buttonStyle, ArkUI_Uint32 buttonRole);
|
/foundation/arkui/ace_engine/frameworks/core/interfaces/arkoala/ |
H A D | arkoala_api.h | 2219 void (*setButtonRole)(ArkUINodeHandle node, ArkUI_Uint32 buttonRole); 2228 void (*setButtonOptions)(ArkUINodeHandle node, ArkUI_Uint32 buttonStyle, ArkUI_Uint32 buttonRole);
|