Skip to content

Commit

Permalink
ToolStatus: Disabled theme combo options; Removed commented code;
Browse files Browse the repository at this point in the history
git-svn-id: svn://svn.code.sf.net/p/processhacker/code@6350 21ef857c-d57f-4fe0-8362-d861dc6d29cd
  • Loading branch information
dmex committed Feb 1, 2016
1 parent f00197c commit 66fe601
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 73 deletions.
4 changes: 2 additions & 2 deletions 2.x/trunk/plugins/ToolStatus/ToolStatus.rc
Original file line number Diff line number Diff line change
Expand Up @@ -124,8 +124,8 @@ BEGIN
"Button",BS_AUTOCHECKBOX | WS_TABSTOP,188,154,157,10
PUSHBUTTON "Reset",IDC_RESET,258,170,50,14
DEFPUSHBUTTON "Close",IDCANCEL,312,170,50,14
LTEXT "Theme:",IDC_STATIC,7,174,45,8
COMBOBOX IDC_THEMEOPTIONS,56,171,123,30,CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP
LTEXT "Theme:",IDC_STATIC,7,174,45,8,NOT WS_VISIBLE
COMBOBOX IDC_THEMEOPTIONS,56,171,123,30,CBS_DROPDOWNLIST | NOT WS_VISIBLE | WS_VSCROLL | WS_TABSTOP
END

IDD_CUSTOMIZE_SB DIALOGEX 0, 0, 373, 142
Expand Down
74 changes: 3 additions & 71 deletions 2.x/trunk/plugins/ToolStatus/customizetb.c
Original file line number Diff line number Diff line change
Expand Up @@ -485,7 +485,8 @@ static VOID CustomizeResetToolbarImages(
VOID
)
{
// Reset the image cache with the new icons
// Reset the image cache with the new icons.
// TODO: Move function to Toolbar.c
for (INT i = 0; i < ARRAYSIZE(ToolbarButtons); i++)
{
if (ToolbarButtons[i].iBitmap != I_IMAGECALLBACK)
Expand All @@ -505,75 +506,6 @@ static VOID CustomizeResetToolbarImages(
}
}
}

// First attempt
//INT buttonIndex;
//INT buttonCount;
//
//buttonCount = (INT)SendMessage(ToolBarHandle, TB_BUTTONCOUNT, 0, 0);
//
//for (buttonIndex = 0; buttonIndex < buttonCount; buttonIndex++)
//{
// TBBUTTON button;
//
// memset(&button, 0, sizeof(TBBUTTON));
//
// if (SendMessage(ToolBarHandle, TB_GETBUTTON, buttonIndex, (LPARAM)&button))
// {
// HBITMAP buttonImage;
//
// if (button.fsStyle & BTNS_SEP)
// continue;
//
// if (buttonImage = ToolbarGetImage(button.idCommand))
// {
// ImageList_Replace(
// ToolBarImageList,
// button.iBitmap,
// buttonImage,
// NULL
// );
// DeleteObject(buttonImage);
// }
// }
//}

// Second attempt
//INT buttonIndex;
//INT buttonCount;
//
//buttonCount = (INT)SendMessage(ToolBarHandle, TB_BUTTONCOUNT, 0, 0);
//
//for (buttonIndex = 0; buttonIndex < buttonCount; buttonIndex++)
//{
// TBBUTTONINFO buttonInfo =
// {
// sizeof(TBBUTTONINFO),
// TBIF_BYINDEX | TBIF_IMAGE | TBIF_STYLE | TBIF_COMMAND
// };
//
// if (SendMessage(ToolBarHandle, TB_GETBUTTONINFO, buttonIndex, (LPARAM)&buttonInfo) != -1)
// {
// HBITMAP buttonImage;
//
// if (buttonInfo.fsStyle & BTNS_SEP)
// continue;
//
// if (buttonImage = ToolbarGetImage(buttonInfo.idCommand))
// {
// ImageList_Replace(
// ToolBarImageList,
// buttonInfo.iImage,
// buttonImage,
// NULL
// );
//
// DeleteObject(buttonImage);
// }
//
// //SendMessage(ToolBarHandle, TB_SETBUTTONINFO, buttonIndex, (LPARAM)&buttonInfo);
// }
//}
}

static INT_PTR CALLBACK CustomizeDialogProc(
Expand Down Expand Up @@ -895,9 +827,9 @@ static INT_PTR CALLBACK CustomizeDialogProc(

ToolbarLoadSettings();

//CustomizeLoadItems(context);
CustomizeResetImages(context);
CustomizeResetToolbarImages();
//CustomizeLoadItems(context);
}
}
break;
Expand Down

0 comments on commit 66fe601

Please sign in to comment.