|
@@ -162,6 +162,17 @@ class iTopWebPage extends NiceWebPage
|
|
|
// This selector will be reused when selecting actual tab widget A elements.
|
|
|
var tab_a_selector = 'ul.ui-tabs-nav a';
|
|
|
|
|
|
+ // Ugly patch for a change in the behavior of jQuery UI:
|
|
|
+ // Before jQuery UI 1.9, tabs were always considered as "local" (opposed to Ajax)
|
|
|
+ // when their href was beginning by #. Starting with 1.9, a <base> tag in the page
|
|
|
+ // is taken into account and causes "local" tabs to be considered as Ajax
|
|
|
+ // unless their URL is equal to the URL of the page...
|
|
|
+ $('div[id^=tabbedContent] ul li a').each(function() {
|
|
|
+ var sHash = location.hash;
|
|
|
+ var sCleanLocation = location.href.toString().replace(sHash, '').replace(/#$/, '');
|
|
|
+ $(this).attr("href", sCleanLocation+$(this).attr("href"));
|
|
|
+ });
|
|
|
+
|
|
|
// Enable tabs on all tab widgets. The `event` property must be overridden so
|
|
|
// that the tabs aren't changed on click, and any custom event name can be
|
|
|
// specified. Note that if you define a callback for the 'select' event, it
|