Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Merge branch 'release-1.14' into develop

* release-1.14:
  (Bug 4934) Abort the ajax request if user moves away from the trigger
  (Bug 4928) ejs the translation string before putting it into JS
  • Loading branch information...
commit 1d6dd7091e3772c7eb37d4fc5d2429baea532fb8 2 parents cfa39cb + 6d95032
@afuna afuna authored
View
16 htdocs/js/jquery.ajaxtip.js
@@ -55,6 +55,15 @@ $.widget("dw.ajaxtip", $.ui.tooltip, {
// this is only a confirmation message. We can fade away quickly
window.setTimeout( function() { self.close(); }, 1500 );
},
+ abort: function () {
+ var self = this;
+ if ( self.requests.length ) {
+ $.each( self.requests, function (i, req) {
+ req.abort();
+ });
+ self.requests = [];
+ }
+ },
load: function(args) {
/* opts is an object (or array of objects) containing overrides:
*
@@ -75,12 +84,7 @@ $.widget("dw.ajaxtip", $.ui.tooltip, {
var self = this;
// abort and remove any old requests
- if ( self.requests.length ) {
- $.each( self.requests, function (i, req) {
- req.abort();
- });
- self.requests = [];
- }
+ self.abort();
if ( self.options.loadingContent ) {
self.option("content", self.options.loadingContent);
View
2  htdocs/js/jquery.contextualhover.js
@@ -59,6 +59,7 @@ function _initIcons(context) {
- if you move the mouse from the trigger to the contextual popup
- as long as the mouse is over the tooltip
- NOT if you move the mouse away from the trigger before the popup is fully visible
+ - NOT if you move the mouse away from the trigger before the ajax request is done
disappears:
- when you move the mouse over then out of the contextual popup
@@ -178,6 +179,7 @@ _create: function() {
out: function(e) {
var persist = trigger.data("popup-persist");
if ( ! persist ) {
+ trigger.ajaxtip( "abort" );
trigger.ajaxtip( "close" );
}
trigger.removeData("popup-persist");
View
4 htdocs/manage/circle/add.bml
@@ -307,11 +307,13 @@ _c?>
my $color_switch_checked = $custom_colors ? "checked=\"checked\"" : "";
$body .= "<div class='add_watch'>";
+
+ my $disclaimer_ejs = LJ::ejs( $ML{".colors.disclaimer" } );
## let them pick the colors
my $color_text = "<?p <table summary=\\'\\'><tr><td valign=\"top\"><i>$ML{'.optional'}:</i> ".
"<input type=\"checkbox\" id=\"color_switch\" name=\"color_switch\" onClick=\"color_display(this);\" $color_switch_checked> </td><td><label for=\"color_switch\">" .
BML::ml( '.colors.text', { user => $username } ) .
- "</label><br /><span style=\"font-size: 7pt;\">($ML{'.colors.disclaimer'})</span></td></tr></table> p?>";
+ "</label><br /><span style=\"font-size: 7pt;\">($disclaimer_ejs)</span></td></tr></table> p?>";
$body .= "<script>\n";
$body .= "function color_display(check) {\n";
$body .= " if (check.checked) {\n";
Please sign in to comment.
Something went wrong with that request. Please try again.