[EFL] Add background color to the checkbox theme.
authorcommit-queue@webkit.org <commit-queue@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Wed, 17 Oct 2012 10:08:53 +0000 (10:08 +0000)
committercommit-queue@webkit.org <commit-queue@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Wed, 17 Oct 2012 10:08:53 +0000 (10:08 +0000)
https://bugs.webkit.org/show_bug.cgi?id=98788

Patch by Byungwoo Lee <bw80.lee@samsung.com> on 2012-10-17
Reviewed by Gyuyoung Kim.

Background color is added to the checkbox theme for identifying
checkbox status easily.

Checkbox theme uses images which has transparent background, and the
theme itself doesn't have the background color.

When the background of checkbox is black, checked/unchecked status
cannot be distinguished because check mark color is black.

And it is hard to identify whether the checkbox is disabled or not,
because there is no background color in the checkbox theme.

Instead of adding background color to the edc script, background
images are added because the shape of the check box can be various.

* DefaultTheme/widget/check/check.edc:
* DefaultTheme/widget/check/img_check_bg_enabled.png: Added.
* DefaultTheme/widget/check/img_check_bg_disabled.png: Added.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@131576 268f45cc-cd09-0410-ab3c-d52691b4dbfc

Source/WebKit/efl/ChangeLog
Source/WebKit/efl/DefaultTheme/widget/check/check.edc
Source/WebKit/efl/DefaultTheme/widget/check/img_check_bg_disabled.png [new file with mode: 0644]
Source/WebKit/efl/DefaultTheme/widget/check/img_check_bg_enabled.png [new file with mode: 0644]

index 9103a77..f8d710e 100644 (file)
@@ -1,5 +1,31 @@
 2012-10-17  Byungwoo Lee  <bw80.lee@samsung.com>
 
+        [EFL] Add background color to the checkbox theme.
+        https://bugs.webkit.org/show_bug.cgi?id=98788
+
+        Reviewed by Gyuyoung Kim.
+
+        Background color is added to the checkbox theme for identifying
+        checkbox status easily.
+
+        Checkbox theme uses images which has transparent background, and the
+        theme itself doesn't have the background color.
+
+        When the background of checkbox is black, checked/unchecked status
+        cannot be distinguished because check mark color is black.
+
+        And it is hard to identify whether the checkbox is disabled or not,
+        because there is no background color in the checkbox theme.
+
+        Instead of adding background color to the edc script, background
+        images are added because the shape of the check box can be various.
+
+        * DefaultTheme/widget/check/check.edc:
+        * DefaultTheme/widget/check/img_check_bg_enabled.png: Added.
+        * DefaultTheme/widget/check/img_check_bg_disabled.png: Added.
+
+2012-10-17  Byungwoo Lee  <bw80.lee@samsung.com>
+
         [EFL] Add background color to the radio button theme.
         https://bugs.webkit.org/show_bug.cgi?id=98852
 
index 0e09303..0f8d43c 100644 (file)
@@ -25,6 +25,8 @@
       min: 12 12;
 
       images {
+         image: "widget/check/img_check_bg_enabled.png" COMP;
+         image: "widget/check/img_check_bg_disabled.png" COMP;
          image: "widget/check/img_check_on.png" COMP;
          image: "widget/check/img_check_off.png" COMP;
          image: "widget/check/img_check_off_focus.png" COMP;
@@ -43,6 +45,7 @@
           public show() {
               if (get_int(isEnabled) == 1) {
                   set_state(PART:"check_button", "default", 0.0);
+                  set_state(PART:"bg", "enabled", 0.0);
                   if (get_int(isChecked) == 1) {
                       set_state(PART:"check_button", "enabled_checked", 0.0);
                       if (get_int(isFocused) == 1)
@@ -59,6 +62,7 @@
               }
               else {
                   set_state(PART:"check_button", "disabled", 0.0);
+                  set_state(PART:"bg", "disabled", 0.0);
                   if (get_int(isChecked) == 1)
                       set_state(PART:"check_button", "disabled_checked", 0.0);
               }
 
       parts {
          part {
+            name: "bg";
+            type: IMAGE;
+            description {
+               state: "default" 0.0;
+               min: 12 12;
+               max: 12 12;
+               image {
+                  normal: "widget/check/img_check_bg_enabled.png";
+               }
+            }
+            description {
+               state: "enabled" 0.0;
+               inherit: "default" 0.0;
+            }
+            description {
+               state: "disabled" 0.0;
+               inherit: "default" 0.0;
+               image {
+                  normal: "widget/check/img_check_bg_disabled.png";
+               }
+            }
+         }
+         part {
             name: "check_button";
             type: IMAGE;
             description {
diff --git a/Source/WebKit/efl/DefaultTheme/widget/check/img_check_bg_disabled.png b/Source/WebKit/efl/DefaultTheme/widget/check/img_check_bg_disabled.png
new file mode 100644 (file)
index 0000000..e624b10
Binary files /dev/null and b/Source/WebKit/efl/DefaultTheme/widget/check/img_check_bg_disabled.png differ
diff --git a/Source/WebKit/efl/DefaultTheme/widget/check/img_check_bg_enabled.png b/Source/WebKit/efl/DefaultTheme/widget/check/img_check_bg_enabled.png
new file mode 100644 (file)
index 0000000..0f1a686
Binary files /dev/null and b/Source/WebKit/efl/DefaultTheme/widget/check/img_check_bg_enabled.png differ