Link pulldowns opened via mouse hovering will now disappear when the mouse is moved away.
This commit is contained in:
parent
929d27035a
commit
033833b00b
3
NEWS
3
NEWS
|
@ -1,4 +1,7 @@
|
||||||
1.5.9:
|
1.5.9:
|
||||||
|
* When you hover the mouse over a link and a link pulldown appears, that
|
||||||
|
pulldown will now automatically disappear soon after you move the mouse
|
||||||
|
away.
|
||||||
* Changed the "new note" key from ctrl-N to ctrl-M so as not to conflict with
|
* Changed the "new note" key from ctrl-N to ctrl-M so as not to conflict with
|
||||||
the "new browser window" key used in most web browsers.
|
the "new browser window" key used in most web browsers.
|
||||||
* Fixed a Chrome/Safari bug in which ending a link didn't always work.
|
* Fixed a Chrome/Safari bug in which ending a link didn't always work.
|
||||||
|
|
|
@ -2975,11 +2975,15 @@ function Pulldown( wiki, notebook_id, pulldown_id, anchor, relative_to, ephemera
|
||||||
|
|
||||||
if ( this.ephemeral ) {
|
if ( this.ephemeral ) {
|
||||||
// when the mouse cursor is moved into the pulldown, it becomes non-ephemeral (in other words,
|
// when the mouse cursor is moved into the pulldown, it becomes non-ephemeral (in other words,
|
||||||
// it will no longer disappear in a few seconds)
|
// it will no longer disappear in a few seconds). but as soon as the mouse leaves, it becomes
|
||||||
|
// ephemeral again
|
||||||
var self = this;
|
var self = this;
|
||||||
connect( this.div, "onmouseover", function ( event ) {
|
connect( this.div, "onmouseover", function ( event ) {
|
||||||
self.ephemeral = false;
|
self.ephemeral = false;
|
||||||
} );
|
} );
|
||||||
|
connect( this.div, "onmouseout", function ( event ) {
|
||||||
|
self.ephemeral = true;
|
||||||
|
} );
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -3306,10 +3310,16 @@ Link_pulldown.prototype.display_summary = function ( title, summary ) {
|
||||||
}
|
}
|
||||||
|
|
||||||
Link_pulldown.prototype.title_field_clicked = function ( event ) {
|
Link_pulldown.prototype.title_field_clicked = function ( event ) {
|
||||||
|
disconnectAll( this.div );
|
||||||
|
this.ephemeral = false;
|
||||||
|
|
||||||
event.stop();
|
event.stop();
|
||||||
}
|
}
|
||||||
|
|
||||||
Link_pulldown.prototype.title_field_focused = function ( event ) {
|
Link_pulldown.prototype.title_field_focused = function ( event ) {
|
||||||
|
disconnectAll( this.div );
|
||||||
|
this.ephemeral = false;
|
||||||
|
|
||||||
this.title_field.select();
|
this.title_field.select();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Reference in New Issue