![]() |
#1 |
Junior Member
Join Date: Apr 2011
Posts: 15
|
Endless Marquee in nsWindows popup
Hi everyone,
Am using the nsWindows plugin to create popups, and almost have the marquee working. My intention was to generate the marquee whenever some work is being done (function being called, etc), just so the user had some some that something was moving. I managed to get the popup to show just fine, but the marquee itself is not - it's just blank. This is the main page: code: This is the leave code (onClickGetKey): code: And this is my timer code: code: I've also attached a screencap of what am seeing. Am thinking I have the wrong Window? |
![]() |
![]() |
![]() |
#2 |
Moderator
Join Date: Nov 2002
Location: Surrey, England
Posts: 8,434
|
This probably isn't working because the window is running in the same thread as your process and therefore the window cannot repaint (the window message loop is blocked). Also a progress bar is either in marque mode or it isn't. You don't need to send PBM_SETMARQUEE every so often; only once.
Stu |
![]() |
![]() |
![]() |
#3 |
Junior Member
Join Date: Apr 2011
Posts: 15
|
Ok, I fixed that part with the marquee mode, but am still stumped on the same thread/process. How can I find what thread/process the code is running in so I don't overlap them?
|
![]() |
![]() |
![]() |
#4 | |
Major Dude
|
I think problem is in NSW. I did not looked into sources but if it is similar to nsDialogs all components [also the timer] are created in one thread = GUI thread which is bad.
Quote:
Use my ThreadTimer plugin as reference: http://nsis.sourceforge.net/ThreadTimer_plug-in By the way I am developing new plug-in specially with this purpose - it creates new separated thread which shows window with Please wait... message and gif animation ![]() Cool looking installers with custom design: www.graphical-installer.com Create Setup Pages easily: www.install-designer.com Build installers in Visual Studio 2005-2019: www.visual-installer.com or RAD Studio 2009, 2010, XE-10.4 Sydney: www.rad-installer.com |
|
![]() |
![]() |
![]() |
#5 |
Junior Member
Join Date: Apr 2011
Posts: 15
|
I will definitely try your plug-in, Slappy.
It's strange, I got it to work within 2 pop-ups, not 3. (So if I have a button to click and pops up a window, that gives me the marquee, but if I have a button to click, which pops up a window with another button to click, that doesn't pop up.) Edit: I tried the ThreadTimer, Slappy, but not sure why it's not working either. I dropped in the DLL into my plugins folder and linked it to my installer. I compiled/built the C code; and I copied your test code but it says that ThreadTimer is invalid. Am I missing something? Should there be an NSH/I header somewhere? |
![]() |
![]() |
![]() |
#6 | |
Major Dude
|
Quote:
Anyway you can take an idea from that plug-in - creating new thread using _beginthreadex Cool looking installers with custom design: www.graphical-installer.com Create Setup Pages easily: www.install-designer.com Build installers in Visual Studio 2005-2019: www.visual-installer.com or RAD Studio 2009, 2010, XE-10.4 Sydney: www.rad-installer.com |
|
![]() |
![]() |
![]() |
#7 | |
Junior Member
Join Date: Apr 2011
Posts: 15
|
Quote:
code: Is there any way to fix this (or any idea how to)? |
|
![]() |
![]() |
![]() |
#8 |
Moderator
Join Date: Nov 2002
Location: Surrey, England
Posts: 8,434
|
|
![]() |
![]() |
![]() |
|
Thread Tools | Search this Thread |
Display Modes | |
|
|