Development :  K-Meleon Web Browser Forum
K-Meleon development related discussions. 
Undo Last Closed
Posted by: Dekan
Date: March 13, 2005 04:38PM

By default, this macro reopens all the layers closed during a session, which I don't find particularly useful. I'd like to change it so it only reopens the last layer, then running it again would reopen the layer before that, and so on. It seems this should be possible by editing the following macro:

OpenClosed{
$how = $rl; $group = getpref(STRING, $gt); $curr = pluginmsgex(layers,$gl,"",STRING);
$group == $curr ? "" : $curr = ""; $curr == "" ? &Group : "" ;
}

but I'm not sure how to do it. Grateful for any help.

Options: ReplyQuote
Re: Undo Last Closed
Posted by: Drahken
Date: March 13, 2005 05:14PM

There's also a bug in this function that causes it to create a ghost clone of k-meleon. Close a layer, use the open(closed) function, then look at your taskbar. You'll see what appears to be a second copy of k-meleon running. If you click on it though, it'll disappear. I suspect that this is related to the "bug" where k-meleon briefly shows another copy of itself in the taskbar when you open a new layer, except that this copy doesn't automatically close itself like that one does.

Options: ReplyQuote
Re: Undo Last Closed
Posted by: jsnj
Date: March 13, 2005 09:19PM

By default, this macro reopens all the layers closed during a session

Not exactly. The Undo Last Closed feature in KM is a workaround. It's not a complete implementation as found in other browsers which have the feature fully. I'll try and explain how it works. Everytime a page loads, all the layers presently open in the window are saved to prefs as a temporary group. So after you close a layer, close other layers, or close all layers, when you use Undo Last Closed, the last saved temporary group is opened which includes your closed layer or layers. So if you just closed 1 layer, that'll be reopened along with the layers presently open as a group. If you closed multiple layers, they'll be reopened along with the layers presently open as a group.


There's also a bug in this function that causes it to create a ghost clone of k-meleon. Close a layer, use the open(closed) function, then look at your taskbar. You'll see what appears to be a second copy of k-meleon running. If you click on it though, it'll disappear. I suspect that this is related to the "bug" where k-meleon briefly shows another copy of itself in the taskbar when you open a new layer, except that this copy doesn't automatically close itself like that one does.

Not at all related to this macro specifically. Happens whenever a group is opened. It's just a byproduct of using the layers plugin. This is one of it's side effects.

Options: ReplyQuote
Re: Undo Last Closed
Posted by: Drahken
Date: March 14, 2005 05:23PM

Happens whenever a group is opened.

Ah. I wasn't aware of that, since I never use the groups.

Options: ReplyQuote
Re: Undo Last Closed
Posted by: Dekan
Date: March 21, 2005 11:48PM

Thanks for the explanation jsnj.

Options: ReplyQuote
Re: Undo Last Closed
Posted by: Arual the Wyrd
Date: June 19, 2005 12:50AM

Interesting, as I've been having to re-open a lot of accidentally closed layers since I switched mice. My A4Tech mini optical mouse has a problem with its left button that causes unintended double-clicks. It makes me do a lot more with the keyboard when it gets into its worst moods. I know, switch mice, but it's comfortable and I can draw a smooth line in the GIMP with it
;-)

This mouse is the one most likely to bring about the sticky-mouse phenomenon, where some hard to define combination of events causes the scrollbar to follow the pointer after the button is released.

Anyway, I just discovered another thing that I think is either a bug or a feature:
reopening the last closed layer by clicking on the scrollbar while holding CTRL down.

It happened several times, and I said to myself WTF and after a few more times I figured out exactly what I had done. Thanks to my wonky mouse, I'm not absolutely sure whether or not it takes a double click LOL

Now--is this a known bug/feetch or have I won the Golden Peanut Prize for Trivial Serendipity?

Options: ReplyQuote
Re: Undo Last Closed
Posted by: jsnj
Date: June 19, 2005 07:08PM

Anyway, I just discovered another thing that I think is either a bug or a feature:
reopening the last closed layer by clicking on the scrollbar while holding CTRL down.


Can't reproduce that here. Is the new mouse programmed to send Ctrl+Alt+Z somehow somewhere? That's the keyboard accelerator for the Undo Last Closed feature.

Options: ReplyQuote
Re: Undo Last Closed
Posted by: Arual the Wyrd
Date: June 22, 2005 10:45PM

I have no idea what this mouse thinks it is doing sometimes LOL. As I said, it produces other odd effects more than a "normal" mouse. I have not installed any of its own special software this time around. I only use it when I am doing a lot of artwork and want the smooth control over movement.

There is definitely something wrong with the left button, though, and it's worse now than ever before. As far as I can tell, all it does is doubleclick when it should single--some kind of bouncing in the switch. Once in a while I poke at it with a toothpick and it behaves better for a while. Of course my computer is a grouchy old thing too. Between the two of them, there could be some misinterpretation of signals. It's absolute hell in a text editor!

I often have a finger hovering over CTRL while browsing, to copy links for my downloader or for switching layers, and my fingers sometimes act when they shouldn't (LOL), which is how I discovered the trick. It is fairly consistently repeatable, though I had some failures when playing with on-disk files.

Oh well, another one of those little mysteries that I love.

Options: ReplyQuote
Re: Undo Last Closed
Posted by: Arual the Wyrd
Date: June 23, 2005 10:35PM

Unhappy moment: I decided to try CTRL+ALT+Z when my hyper mouse last killed a layer, because I couldn't get my odd trick to work. It opened the last layer all right--and closed all the rest!!! I'm going back to right-clicking a layer for that command. Life is getting complicated *rolls eyes*

Options: ReplyQuote
Re: Undo Last Closed
Posted by: burnman99
Date: June 26, 2005 12:01AM

you can set up undo last closed as a mouse gesture and use it that way. I use gesture down to close a layer and up to undo a close. Works great for me!

Hope this helps

Rog

Options: ReplyQuote
Re: Undo Last Closed
Posted by: Arual the Wyrd
Date: June 27, 2005 03:16AM

The way I fall asleep and twitch at the switch here I wouldn't trust myself with mouse gestures. Never tried them anyway, since I always have a cranky mouse one way or another, and a cranky computer. I would probably open three new windows and reboot if I sneezed.

Anyway, I found out what is probably doing the apparent re-opening. It's just link-overlap, or whatever you might want to call it. The cursor is legally on the scrollbar, but clicking at that point triggers a nearby link. I have a little HTML viewer that does it more obviously--the cursor even changes, and until I "click the curse off" by making a left-click somewhere away from the scrollbar, its whole scrollbar is an extension of the nearest active link on a newly opened page.

An improbable set of coincidences made it look as if a layer was re-opening, when what really happened was that I opened the same link again by clicking its scrollbar-ghost. Am I making any sense? LOL.

Options: ReplyQuote
Re: Undo Last Closed
Posted by: Arual the Wyrd
Date: June 29, 2005 01:26AM

Uhm... now I'm really confused. A previously closed layer just reopened, and I had closed the page that I opened it from some time ago. The only thing that I did was give the scrollbar a good yank down, no finger on any key. I'm starting to feel like I have a haunted browser.

I have renamed the mousegestures dll at both ends, in case K-M is confused. Everything else is confused today, my firewall can't remember which progs to trust either. The computer is senile, I think (why I should think that a comper that was given up for dead two years ago might be suffering from age, I really don't know).

Options: ReplyQuote
Re: Undo Last Closed
Posted by: J.C.A.N
Date: July 04, 2005 08:10AM

In the menu I like to just use the close layer in the layer your presently viewing but what happens also is upon closing a present viewed layer it closes another layer that has nothing to do with the layer your trying to close. Hao's build also had this effect when using tabs. I've mentioned this before in a post but I think a good idea would be to incorporate a go button instead of relying on the keyboard enter tab, which doesn't always work for me so the only way in which I could implement going to another site on Hao's build's was that seperate toolbar that would show up with the curved arrow which was the go button on that build.

With Ninja I couldn't use the enter tab on my keyboard to excute a browse of a site, speed is excellent but as I posted on the Ninja subject here I would like to know how to get a site to browse.

J.C.A.N

Options: ReplyQuote
Re: Undo Last Closed
Posted by: jsnj
Date: July 04, 2005 07:20PM

JCAN, sorry, but your post is confusing. What build are you using and asking about and does your post have anything to do with the 'Undo Last Closed' feature?

Options: ReplyQuote
Re: Undo Last Closed
Posted by: Drahken
Date: July 08, 2005 07:51PM

I've noticed an odd little bug that could potentially be made into a useful function. This bug relies on a slow connection to the server, so those of you on broadband may not be able to test it unless you find an extremely slow site. Also note that the timing on this makes it very difficult to pull off intentionally.
Click a link on a page, while it's still displaying the former page, but reaches the point just before it stops responding (ie, won't scroll, links won't click, etc) middle click a link to open it in a new tab. If you're timing is just right, you will get the last tab that you closed instead of whatever the link was supposed to be.
Now, if someone could figure out exactly how that bug works and make it something you could do whenever you choose, then we could have a TRUE "open last closed" feature.

Options: ReplyQuote


K-Meleon forum is powered by Phorum.