Add control mark color setting. #8054

An enhancement adding a setting to Colors under Appearance to
set the mark color of radio button and check box controls.
This commit is contained in:
John Scipione
2012-07-15 15:09:04 -04:00
parent 17ef26a9f8
commit 4bb5af765f
6 changed files with 10 additions and 8 deletions
+5 -4
View File
@@ -26,23 +26,24 @@ static inline int32
color_which_to_index(color_which which)
{
// NOTE: this must be kept in sync with InterfaceDefs.h color_which!
if (which <= B_WINDOW_INACTIVE_BORDER_COLOR)
if (which <= B_CONTROL_MARK_COLOR)
return which - 1;
if (which >= B_SUCCESS_COLOR && which <= B_FAILURE_COLOR)
return which - B_SUCCESS_COLOR + B_WINDOW_INACTIVE_BORDER_COLOR;
return which - B_SUCCESS_COLOR + B_CONTROL_MARK_COLOR;
return -1;
}
static inline color_which
index_to_color_which(int32 index)
{
if (index >= 0 && index < kNumColors) {
if ((color_which)index < B_WINDOW_INACTIVE_BORDER_COLOR)
if ((color_which)index < B_CONTROL_MARK_COLOR)
return (color_which)(index + 1);
else {
return (color_which)(index + B_SUCCESS_COLOR
- B_WINDOW_INACTIVE_BORDER_COLOR);
- B_CONTROL_MARK_COLOR);
}
}