mIRC Home    About    Download    Register    News    Help

Print Thread
Page 1 of 2 1 2
#166252 08/12/06 10:40 AM
Joined: Dec 2006
Posts: 18
B
bits Offline OP
Pikka bird
OP Offline
Pikka bird
B
Joined: Dec 2006
Posts: 18
Under Windows Vista there is a slight redraw issue. I haven't done a heap of testing but to reproduce:
a)channel bar at bottom
b)move mouse up and down over the text input and channel bar as quick as you can(this helps make it appear, but does just randomly appear often)
Now just to the right of the mouse cursor should be a slight ghost "glitchy" looking cursor of the verticle resize cursor(but more carton like because of it's thickness and roundness) appearing only for a few milliseconds(be quick).
It does not matter if the window is fullsize or not and the cursor is not the current verticle resize cursor selected for windows.

To see if it matters this is Vista Ultimate RTM with a TFT 19" screen on a nVidia 6800gt running 96.86 drivers(default out the box Windows Vista Ultimate RTM driver)

As a side note, the weblinks under the help menu namely "Latest News" and "Message Board", open in Internet Explorer even when that is not the selected default browser. Plus all the links that are opened from text inside the chat window

Last edited by bits; 08/12/06 10:52 AM.
Joined: Feb 2006
Posts: 65
F
Babel fish
Offline
Babel fish
F
Joined: Feb 2006
Posts: 65
Quote:
As a side note, the weblinks under the help menu namely "Latest News" and "Message Board", open in Internet Explorer even when that is not the selected default browser.


i had that too for some time, but after testing, i found out it was with vista, not mirc, if u run firefox or what ever brower u want default, as a admin (in the right click menu) and then have it reset its self as default, it should work


known on irc as MrStonedOne
read my full post before replying or dont reply. tl;dr isn't allowed here
Joined: Dec 2006
Posts: 18
B
bits Offline OP
Pikka bird
OP Offline
Pikka bird
B
Joined: Dec 2006
Posts: 18
It is set as default already. Feedreader, slimserver, even Windows Live Messenger and the list does go on, all open their links in firefox.

Joined: Dec 2002
Posts: 5,411
Hoopy frood
Offline
Hoopy frood
Joined: Dec 2002
Posts: 5,411
Regarding the web browser issue under Vista, I can't seem to reproduce the issue here. When I run mIRC and open a link from the Help menu, mIRC uses Explorer as expected. If I install Firefox and then open a link, mIRC uses Firefox. If I uninstall and reinstall, and test inbetween, the behaviour is as expected.

I did notice one thing though: if I have Firefox installed and set as the default browser, Explorer still thinks it is the default browser. I check the Explorer "Internet Options/Programs" dialog and it says it is the default. I then check in the Firefox "Main/Options" dialog, and click "Check Now" and it says it is the default. So both browsers think they are the default browser and give no warnings on startup about not being the default.

The only thing I can think of is that this is an issue with Vista's Virtual Store feature, which does not permit an application to modify the main registry if it does not have administrator rights. This may be causing other applications to read incorrect registry information as well.

Joined: Dec 2006
Posts: 18
B
bits Offline OP
Pikka bird
OP Offline
Pikka bird
B
Joined: Dec 2006
Posts: 18
How is mirc deciding which browser to use?
Something is horribly wrong in its logic..
please do get "technical" with registry entries read etc or method used.

I have now tested this to no end.
Tell me when you install Firefox 1.5.0.8 and have it set as default, check that mirc opens links in firefox. Now go into "Program Defaults" and set Internet Explorer as the default browser.. Do the links now STILL open in Firefox, until you uninstall Firefox.

Note all other programs I have tested (and this is over 10 programs on my machine) work 100% perfect, mirc is the odd one out not following the current settings in Default Programs. I also do not get the issue with IE being confused if it is default or not, it always correctly reports this.

Are you tesing on Vista RTM(in my case Ultimate but this should not matter)?

Any clues about the visual issue with the cursor? is it unique to my machine or can you recreate that?

Last edited by bits; 12/12/06 08:19 AM.
Joined: Dec 2002
Posts: 5,411
Hoopy frood
Offline
Hoopy frood
Joined: Dec 2002
Posts: 5,411
With a clean install of Windows Vista RTM Ultimate (and updates) and no other software installed:

After I install Firefox, both Firefox and Internet Explorer think they are the default browser. Neither one warns on startup about not being the default browser. At that point, I am unable to change the default browser at all.

If I then install mIRC, mIRC will only use Firefox. If I uninstall Firefox, mIRC then uses Internet Explorer.

In answer to your question about your other applications opening the correct browser: most applications simply ask Windows to open a web page, and then Windows itself determines the default browser.

mIRC however needs to determine the browser executable and the DDE topic so that it can control how the browser opens, via DDE if necessary, per the settings in the mIRC Options/Catcher dialog. It does this by looking at the HKCR "http" section of the registry to determine the default browser and DDE topic. If mIRC does not find a valid http entry, it asks Windows to open the web page.

Joined: Dec 2002
Posts: 2,031
R
Hoopy frood
Offline
Hoopy frood
R
Joined: Dec 2002
Posts: 2,031
Quote:
most applications simply ask Windows to open a web page, and then Windows itself determines the default browser.


Maybe you could save yourself many headaches from default
browser issues by also letting Windows handle it?

Joined: Oct 2004
Posts: 8,330
Hoopy frood
Offline
Hoopy frood
Joined: Oct 2004
Posts: 8,330
I'd say it's an issue with the browser(s) not setting the registry value(s) correctly more than a problem with mIRC. Considering this is in regards to Vista and not pre-Vista, I'd suggest bringing it to the attention of Firefox devs so they can find out why it's not setting the registry correctly and perhaps fix it. As for IE, I don't know that letting M$ know will get anything done on their end, but you could also try that.

Khaled, maybe it would be helpful for people who have default browser problems if you could post the location of the default browser setting in the registry as a sticky. Then, anyone who feels like editing the registry (warn them of the danger) can change it to be the correct browser.


Invision Support
#Invision on irc.irchighway.net
Joined: Dec 2006
Posts: 18
B
bits Offline OP
Pikka bird
OP Offline
Pikka bird
B
Joined: Dec 2006
Posts: 18
Riamus2, it is a limitation of how mirc is currently set to work, which is wrong. Firefox(trunk) and IE are settings things correctly.

It does appear some versions(namely ONLY 1.5.0.8 and possibly prior) of Firefox added HKCR\http\shell\open\command\ on Vista, which appears to be the same thing mirc is reading. The Firefox trunk(3.x) has most the changes related to Vista and does not do this. IE also does not touch this setting.

only Firefox 1.5.0.8 adds:
HKCR\http\Default Icon\
(Default)=C:\PROGRA~1\MOZILL~2\FIREFOX.EXE,1
HKCR\http\shell\open\command\
(Default)=C:\PROGRA~1\MOZILL~2\FIREFOX.EXE -url "%1"
HKCR\http\shell\open\ddeexec\
(Default)="%1",,0,0,,,,
NoActivateHandler=
HKCR\http\shell\open\ddeexec\Application
(Default)=Firefox
HKCR\http\shell\open\ddeexec\Topic
(Default)="WWW_OpenURL"

The ddeexec settings are removed if IE is set as the default. It does not modify the remaining settings.

I dont think these settings are suppose to exist on Vista at all(similar for ftp, gopher, https, chrome and Mailto for Thunderbird). It was purely a bug/mistake that has since been corrected.
It will be best to pick up the browser from:
HKEY_CURRENT_USER\Software\Microsoft\Windows\Shell\Associations\UrlAssociations\http
which will in firefox's case, point you to:
HKEY_CLASSES_ROOT\FirefoxURL
and if Internet Explorer:
HKEY_CLASSES_ROOT\IE.HTTP

Currently if Firefox 1.5.0.8 is installed it means mirc will ONLY use Firefox. In all other cases and versions, including 1.5.0.9 branch, mirc will fail to find the required key and IE will be used. Unless ofcourse you want to manually edit the registry.

Last edited by bits; 13/12/06 02:17 AM.
Joined: Dec 2002
Posts: 5,411
Hoopy frood
Offline
Hoopy frood
Joined: Dec 2002
Posts: 5,411
Just to make sure, I tested again. I installed a new clean copy of Windows Vista Ultimate RTM, and downloaded the latest updates from the Microsoft website.

I then downloaded and installed Firefox 2.0 and ran it, making sure it was set to be the default browser and to warn in future if it wasn't. I closed it.

I checked .htm/.html/http/https in the registry: they were correctly set to Firefox.

I ran Internet Explorer. It warned me it wasn't the default browser. So I told it to make itself the default and to warn in future if it wasn't. I closed it.

I checked .htm/.html/http/https in the registry: they were still set to Firefox.

I ran Firefox. It didn't warn about not being the default. I checked the Tools/Options/Main dialog and clicked "Check Now" and it told me it was already the default browser.

At this point, both Internet Explorer and Firefox think they're the default browser, and .htm/.html/http/https in the registry are set to use Firefox as the default browser. This means that Internet Explorer and Firefox are setting and/or looking at different registry settings to become the default browser.

I looked at the Shell/Associations/UrlAssociations keys you mentioned. They were set to IE.HTTP both before and after installing/running Firefox.

If there is some logic to the above and there is a definitive method to finding the default browser under Vista, please let me know and I will implement it in mIRC. As far as I know, mIRC is currently using the correct method to determine the default browser that works under all other versions of Windows.

Joined: Dec 2006
Posts: 18
B
bits Offline OP
Pikka bird
OP Offline
Pikka bird
B
Joined: Dec 2006
Posts: 18
I said to use firefox trunk not 2.x I also noticed firefox 2.x handles Vista worse than 1.5.0.x, this is why I did not mention or suggest using it. I will get the MSDN documentation about default browser on Vista if you really need proof you are getting it from the wrong place.

All your reported issues with default browser confusion etc are based around the fact the firefox versions you are using are not correctly setting themself as the default browser.

You can download a trunk build here:
http://ftp.mozilla.org/pub/mozilla.org/firefox/nightly/latest-trunk/

Last edited by bits; 14/12/06 09:08 PM.
Joined: Dec 2002
Posts: 5,411
Hoopy frood
Offline
Hoopy frood
Joined: Dec 2002
Posts: 5,411
Thanks for the information. Like most users, I use the most recent stable public release of Firefox which is Firefox 2.0. That is the version that I test mIRC with.

I'll read up about the UrlAssociations key under Vista, however if I make mIRC only use that key to determine the default browser it will end up not working with any version of Firefox other than the trunk release since, as you say, all versions of Firefox other than the trunk release set the default browser key incorrectly under Vista.

Once a new stable public version of Firefox is released I will take a look at what it's doing (assuming it doesn't change the method by then) and will try to find a way to cater for both the new and old versions of Firefox.

Joined: Dec 2006
Posts: 18
B
bits Offline OP
Pikka bird
OP Offline
Pikka bird
B
Joined: Dec 2006
Posts: 18
The method will not change, it is a requirement for Vista compatibility and is set in stone by Microsoft. This issue was a blocker for Firefox 2.0 but a fix did not land in time and the blocking status was removed. I will say 2.1 will be Vista compatible.

You can read up about the new requirements for Vista here:
http://msdn2.microsoft.com/en-US/library/aa969375.aspx
and here:
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/dnlong/html/AppComp.asp
Goto the "Default Programs" section.

Note currently Mirc does not get the correct default browser on Vista regardless. With older versions, Mirc will use Firefox even if IE is set as the default browser. Which is as wrong as using IE when Firefox 3.x is set as default.
Another note is the reflow branch landed a week ago, Firefox trunk now passes acid 2 test perfectly, why use anything else wink

Honestly IMHO, the fact 2.0 does not work correctly is because 2.0 is not compatible with Vista. You should not support it under the Vista environment. You can not write code to work out if older Firefox's or IE are the default browser, as the two coexist without conflict with the mismatch in settings(hence why both say they are the default). Trying to write a work around for a browser that just simply does not work on Vista seems pointless. The method I have described has nothing to do with IE, firefox or other, it just is how the default browser is set on Vista.

Last edited by bits; 15/12/06 02:31 PM.
Joined: Dec 2006
Posts: 18
B
bits Offline OP
Pikka bird
OP Offline
Pikka bird
B
Joined: Dec 2006
Posts: 18
I got bored so fumbled my way thru mirc scripting.
Now this is my first EVER attempt at mirc script so point out where I have gone wrong and could improve please(but dont be to hard on me I want to learn)!
Basically put all the below as a remote.
To note I ripped 3 random scripts off pretty bad and I forget who they all were, uh sorry to them for lacking credit.
This script will fix the behaviour of Mirc on Vista for opening links (double click a link to open it in the system DEFAULT browser.)

Code:
alias RegRead {
  if ($1 != $null) {
    var %a = regread
    .comopen %a WScript.Shell
    if !$comerr {
      var %b = $com(%a,RegRead,3,bstr,$1-)
      var %c = $com(%a).result
      .comclose %a
      if (%c != $null) return %c
      else {
        return error! when reading or key does not exist
      }
    }
  }
  else { return error! complete data }
}

alias replacew {
  var %a = $1, %g = $iif(3 // $calc($0 - 1),3,2), %i = 2, %re, %v1
  while ($eval($+($,%i),2) != $null) {
    %v1 = $v1
    %n = $eval($ $+ $calc(%i + 2),2)
    if (3 // $calc($0 - 1)) %re = /((?:\Q $+ $replacex(%v1,&,\E\S+\Q,*,\E\S*?\Q,?,\E\S\Q,\E,\E\\E\Q) $+ \E ){ $+ $calc($eval($ $+ $calc(%i + 2),2) - 1) $+ })\Q $+ $replacex(%v1,&,\E\S+\Q,*,\E\S*?\Q,?,\E\S\Q,\E,\E\\E\Q) $+ \E/i
    else %re = $+(/\Q,$replacex(%v1,&,\E\S+\Q,*,\E.*\Q,?,\E.\Q,\E,\E\\E\Q),\E/gi)
    .echo -q $regsub(%a,%re,\1 $+ $replace($eval($+($,$calc(%i + 1)),2),\,\\,$,\$),%a)
    inc %i %g
  }
  return %a
}

on *:hotlink:*//*.*:*: http $1
on *:hotlink:*www.*:*: http $1
alias http {
  var %ProgID = $RegRead(HKCU\Software\Microsoft\Windows\Shell\Associations\UrlAssociations\http\UserChoice\ProgID)
  var %Browser = $RegRead( HKCR\ $+ %ProgID $+ \shell\open\command\ )
  var %Launch = $replacew(%Browser, .exe*, .exe" " $+ $1")
  run %Launch
}

Oh and I had Windows version check working but assumed noone would run the script but those on Vista wink

Joined: Feb 2006
Posts: 65
F
Babel fish
Offline
Babel fish
F
Joined: Feb 2006
Posts: 65
i dont see anything wrong at 1st glance, but a side note:
useing if ($1) etc.. instad of if ($1 != $null) is easyer even if $1 { }

and useing if !$1 { return } is faster

welcome to mirc scripting

Last edited by FaiNT; 24/12/06 09:02 AM.

known on irc as MrStonedOne
read my full post before replying or dont reply. tl;dr isn't allowed here
Joined: Oct 2005
Posts: 1,741
G
Hoopy frood
Offline
Hoopy frood
G
Joined: Oct 2005
Posts: 1,741
if ($1 == $null) {
and
if ($1) {

are not the same. If $1 is set to 0 or $false, the first statement will be $true, whereas the second statement will be $false.

-genius_at_work

Joined: Oct 2004
Posts: 8,330
Hoopy frood
Offline
Hoopy frood
Joined: Oct 2004
Posts: 8,330
genius_at_work, you meant that:

if ($1 != $null) {
and
if ($1) {

aren't the same. smile

And for the OP, if you know that you aren't going to have 0 or $false in $1, then it won't matter... just make sure you know that ahead of time.


Invision Support
#Invision on irc.irchighway.net
Joined: Oct 2005
Posts: 1,741
G
Hoopy frood
Offline
Hoopy frood
G
Joined: Oct 2005
Posts: 1,741
No, I said what I meant. The fact that they will give different results for 0 and $false. Although, in that particular case, $1 could equal the text "$false" and it would still be true for "if ($1) {" because the $false isn't evaluated twice.

-genius_at_work

Joined: Feb 2003
Posts: 810
C
Hoopy frood
Offline
Hoopy frood
C
Joined: Feb 2003
Posts: 810
Riamus2 was talking about your typo. You said "if ($1 == $null)" when you meant "if ($1 != $null)".
Well, in case you didn't mean the latter, you're wrong - after all, ($1 == $null) and ($1) are the same (equally false) when $1 is 0 or $false. grin

And you're wrong about "if ($1)" being true when $1 is "$false": $false returns itself (as does $true). The mIRC interpreter checks its result, just like with any other identifier, but the result in this case is "$false" itself. So, it doesn't matter if you're providing the literal text or the identifier in the statement, because mIRC will treat them equally.
Try: //tokenize 32 $!false | if (!$1) echo -a even the literal "$false" is false

Last edited by cold; 25/12/06 06:14 AM.

* cold edits his posts 24/7
Joined: Oct 2004
Posts: 8,330
Hoopy frood
Offline
Hoopy frood
Joined: Oct 2004
Posts: 8,330
Yes, I was referring to the typo.

As for what else you said, cold, you're wrong. smile

Type these lines to see:

//var %test = $null | if (%test != $null) { echo -a hi }
//var %test = $false | if (%test != $null) { echo -a hi }
//var %test = 0 | if (%test != $null) { echo -a hi }

Then:
//var %test = $null | if (%test) { echo -a hi }
//var %test = $false | if (%test) { echo -a hi }
//var %test = 0 | if (%test) { echo -a hi }

You'll find that the results are not the same.


Invision Support
#Invision on irc.irchighway.net
Page 1 of 2 1 2

Link Copied to Clipboard