|
|
|
|
#1 |
|
Junior Member
Join Date: Apr 2011
Posts: 14
|
UAC plugin, installer window goes behind
using the nullsoft UAC plugin v0.2.2d.zip, i find that the installer window often launches behind other windows (like the browser that opened it).
any ideas how to force it front most? |
|
|
|
|
|
#2 |
|
Moderator
Join Date: Jun 2002
Location: ${NSISDIR}
Posts: 5,442
|
You could try 2.3, I can't remember if it is fixed there or not.
IntOp $PostCount $PostCount + 1 |
|
|
|
|
|
#3 |
|
Junior Member
Join Date: Apr 2011
Posts: 14
|
I tried 2.3 but I think it didn't work on Vista (I should reverify this).
Nonetheless, was this a known bug and fixed at some point? |
|
|
|
|
|
#4 |
|
Major Dude
Join Date: Oct 2006
Posts: 1,892
|
This is a known issue (somewhat), but like Anders said, he doesn't remember whether he already fixed it or not.
|
|
|
|
|
|
#5 |
|
Junior Member
Join Date: Apr 2011
Posts: 14
|
if a fix was made to bring the installer window frontmost, can you kindly tell me where in the code? i will compare the two builds to confirm which version has the fix. thanks.
|
|
|
|
|
|
#6 |
|
Moderator
Join Date: Jun 2002
Location: ${NSISDIR}
Posts: 5,442
|
There is no simple fix you can just apply
IntOp $PostCount $PostCount + 1 |
|
|
|
|
|
#7 |
|
Member
Join Date: Jan 2011
Posts: 69
|
No? What about System::Call 'user32::SetForegroundWindow(i r0)' in .onGuiInit?
EDIT: $0 (r0) should contain the Installer HWND Last edited by Highcoder; 12th April 2011 at 16:35. Reason: forgot something |
|
|
|
|
|
#8 |
|
Moderator
Join Date: Jun 2002
Location: ${NSISDIR}
Posts: 5,442
|
SetForegroundWindow only works if your process has set foreground rights (During .onInit we have no window and so we lose the foreground "lock")
IntOp $PostCount $PostCount + 1 |
|
|
|
|
|
#9 |
|
Member
Join Date: Jan 2011
Posts: 69
|
*facepalm* yes you are right. :-) (or not? i wrote .onGUIinit not .onInit)
An if you put this in the "show_function" of the first window? Or create a (immediately leaved) custom page before the first internal page and put this in the leave_function? cheers Last edited by Highcoder; 13th April 2011 at 07:48. |
|
|
|
|
|
#10 |
|
Major Dude
Join Date: Oct 2006
Posts: 1,892
|
Feel free to give it a try and find out. :-)
I don't have this problem because I don't elevate in .onInit, but that opened up a whole other bag of trouble. Like, getting the outer instance to hide properly. |
|
|
|
|
|
#11 |
|
Member
Join Date: Jan 2011
Posts: 69
|
I don´t have to... user pbeisel have to try it. :-)
I have no problem. |
|
|
|
|
|
#12 |
|
Junior Member
Join Date: Apr 2011
Posts: 2
|
hi all,
first, just wanted to thank everyone for nsis. i have worked with a bunch of installers over the years and my experience with nsis has been, by far, the best. thanks for the hard work and great product! at the moment, i am struggling with the uac plugin. i think my issue is similar to the one being discussed here. when running my installer, when i get to the elevate permissions step, the dialog doesn't show up on the screen -- instead, i just see a shield icon in the tray at the bottom of the screen. when i click the shield, then is see the dialog. after that, everything works correctly. but i am concerned the my customers won't see shield and will get stuck. i am hoping there is just a problem with my installer script. does anyone know what might be causing this? i noticed that the dropbox installer (http://www.dropbox.com) appears to use nsis and the uac plugin and their elevate permissions dialog shows up right away as it should. anyone have any ideas? thanks |
|
|
|
|
|
#13 |
|
Major Dude
Join Date: Oct 2006
Posts: 1,892
|
Where are you trying to elevate? .onInit? .onGuiInit? Somewhere else?
|
|
|
|
|
|
#14 |
|
Junior Member
Join Date: Apr 2011
Posts: 2
|
we are elevating in onInit()
code: |
|
|
|
|
|
#15 |
|
Major Dude
Join Date: Mar 2003
Posts: 571
|
What is the RequestExecutionLevel setting in your script?
|
|
|
|
|
|
#16 |
|
Major Dude
Join Date: Oct 2006
Posts: 1,892
|
I don't think that should matter, as far as I know UAC_elevate will runas admin $EXEPATH regardless of the current level.
I guess if noone else has a solution, you could always try elevating after the window has been created... >_> |
|
|
|
|
|
#17 |
|
Moderator
Join Date: Jun 2002
Location: ${NSISDIR}
Posts: 5,442
|
Asking about RequestExecutionLevel is pointless, if you set it to admin, the plugin becomes pointless and has no effect
IntOp $PostCount $PostCount + 1 |
|
|
|
|
|
#18 | |
|
Major Dude
Join Date: Sep 2005
Location: Somewhere over the Slaughterhouse
Posts: 797
|
Quote:
My Plugins: StdUtils | NSISList | CPUFeatures | ExecTimeout | KillProc My source of inspiration: http://youtu.be/lCwY4_0W1YI |
|
|
|
|
![]() |
|
|||||||
| Thread Tools | Search this Thread |
| Display Modes | |
|
|