Click here to Skip to main content
15,891,629 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
AnswerRe: visual c++ Pin
Eytukan1-Mar-09 2:43
Eytukan1-Mar-09 2:43 
GeneralRe: visual c++ Pin
Hamid_RT1-Mar-09 4:28
Hamid_RT1-Mar-09 4:28 
GeneralRe: visual c++ Pin
Eytukan1-Mar-09 6:33
Eytukan1-Mar-09 6:33 
GeneralRe: visual c++ Pin
Hamid_RT1-Mar-09 4:28
Hamid_RT1-Mar-09 4:28 
AnswerRe: visual c++ Pin
Jonathan Davies28-Feb-09 12:54
Jonathan Davies28-Feb-09 12:54 
QuestionFlashing Toolbar Buttons Pin
softwaremonkey28-Feb-09 7:41
softwaremonkey28-Feb-09 7:41 
AnswerRe: Flashing Toolbar Buttons Pin
Code-o-mat28-Feb-09 7:51
Code-o-mat28-Feb-09 7:51 
GeneralRe: Flashing Toolbar Buttons Pin
softwaremonkey1-Mar-09 6:16
softwaremonkey1-Mar-09 6:16 
Hi,

Thanks for the suggestion. I tried it and it looked OK but still not quite what I wanted. For info, I did manage to get the look I was after but I dont know if its the "correct" way to do it. I created two versions of the toolbar bitmap each showing the two states I needed. I loaded them into two image lists in CMainFrame::OnCreate(). I then swapped the image list into the toolbar on a timer, like this...

CMainFrame::OnCreate(LPCREATESTRUCT lpCreateStruct)
{
...
	m_il1.Create(IDR_MAINFRAME1, 32, 0,RGB(128,128,128)); // Load the two toolbar bitmaps
	m_il2.Create(IDR_MAINFRAME2, 32, 0,RGB(128,128,128)); 
...
}

CMainFrame::FlashToolbarButton()
{
// Called from a windows timer
	static bool bSwap = true;
	if(bSwap)
	{
		m_wndToolBar.GetToolBarCtrl().SetImageList(&m_il1);
		bSwap = FALSE;
	}
	else
	{
		m_wndToolBar.GetToolBarCtrl().SetImageList(&m_il2);
		bSwap = TRUE;
	}
	m_wndToolBar.Invalidate(); // Needed to redraw the toolbar
}


Probably very ugly - maybe someone else has a more elegant solution. Smile | :)
GeneralRe: Flashing Toolbar Buttons Pin
Code-o-mat1-Mar-09 6:57
Code-o-mat1-Mar-09 6:57 
QuestionMethod template in a class template [compiling error, help] [modified] Pin
jim258kelly28-Feb-09 6:08
jim258kelly28-Feb-09 6:08 
NewsRe: Method template in a class template [compiling error, help] [modified] Pin
jim258kelly28-Feb-09 7:30
jim258kelly28-Feb-09 7:30 
AnswerRe: Method template in a class template [compiling error, help] Pin
Stuart Dootson28-Feb-09 9:37
professionalStuart Dootson28-Feb-09 9:37 
GeneralRe: Method template in a class template [compiling error, help] Pin
jim258kelly28-Feb-09 10:34
jim258kelly28-Feb-09 10:34 
GeneralRe: Method template in a class template [compiling error, help] Pin
Stuart Dootson28-Feb-09 11:31
professionalStuart Dootson28-Feb-09 11:31 
QuestionString table Updation Pin
Alex@9C28-Feb-09 5:39
Alex@9C28-Feb-09 5:39 
AnswerRe: String table Updation Pin
Code-o-mat28-Feb-09 7:37
Code-o-mat28-Feb-09 7:37 
QuestionPicture Control Pin
daavena28-Feb-09 5:36
daavena28-Feb-09 5:36 
AnswerRe: Picture Control Pin
Code-o-mat28-Feb-09 7:42
Code-o-mat28-Feb-09 7:42 
GeneralRe: Picture Control Pin
daavena28-Feb-09 7:49
daavena28-Feb-09 7:49 
GeneralRe: Picture Control Pin
Code-o-mat28-Feb-09 7:52
Code-o-mat28-Feb-09 7:52 
GeneralRe: Picture Control Pin
daavena28-Feb-09 8:19
daavena28-Feb-09 8:19 
GeneralRe: Picture Control [modified] Pin
Code-o-mat28-Feb-09 8:31
Code-o-mat28-Feb-09 8:31 
GeneralRe: Picture Control Pin
daavena28-Feb-09 9:09
daavena28-Feb-09 9:09 
GeneralRe: Picture Control [modified] Pin
Code-o-mat28-Feb-09 9:22
Code-o-mat28-Feb-09 9:22 
GeneralRe: Picture Control Pin
daavena28-Feb-09 9:46
daavena28-Feb-09 9:46 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.