refinerycms 0.9.6.14 → 0.9.6.15
Sign up to get free protection for your applications and to get access to all the features.
- data/.gitignore +4 -1
- data/Rakefile +3 -51
- data/VERSION +1 -1
- data/bin/refinery +20 -20
- data/bin/refinery-override +9 -9
- data/bin/refinery-update-core +41 -34
- data/config/application.rb +28 -87
- data/config/environment.rb +1 -4
- data/config/environments/development.rb +2 -0
- data/config/environments/production.rb +1 -1
- data/config/preinitializer.rb +2 -6
- data/db/schema.rb +1 -1
- data/db/seeds.rb +1 -1
- data/lib/refinery/tasks/refinery.rake +83 -0
- data/lib/refinery/tasks/refinery.rb +16 -0
- data/public/images/refinery/dialogLoadingAnimation.gif +0 -0
- data/public/javascripts/refinery/admin.js +9 -4
- data/public/javascripts/refinery/boot_wym.js +19 -5
- data/public/javascripts/wymeditor/jquery.refinery.wymeditor.js +72 -70
- data/public/stylesheets/refinery/refinery.css +19 -7
- data/readme.md +2 -2
- data/test/fixtures/user_plugins.yml +36 -0
- data/test/fixtures/users.yml +1 -2
- data/test/functional/dashboard_controller_test.rb +23 -3
- data/test/functional/images_controller_test.rb +93 -0
- data/test/test_helper.rb +9 -3
- data/test/unit/image_test.rb +2 -2
- data/test/unit/inquiry_test.rb +6 -6
- data/test/unit/news_items_test.rb +8 -8
- data/test/unit/refinery_setting_test.rb +12 -12
- data/test/unit/resource_test.rb +3 -3
- data/themes/demolicious/views/layouts/application.html.erb +1 -1
- data/themes/demolicious/views/pages/home.html.erb +1 -1
- data/themes/demolicious/views/pages/show.html.erb +1 -1
- data/themes/hemingway/views/layouts/application.html.erb +1 -1
- data/vendor/plugins/dashboard/app/controllers/admin/dashboard_controller.rb +1 -1
- data/vendor/plugins/dashboard/rails/init.rb +1 -1
- data/vendor/plugins/images/app/controllers/admin/images_controller.rb +2 -2
- data/vendor/plugins/images/app/helpers/admin/images_helper.rb +6 -2
- data/vendor/plugins/images/app/models/image.rb +3 -3
- data/vendor/plugins/images/app/views/admin/images/_form.html.erb +4 -4
- data/vendor/plugins/images/app/views/admin/images/index.html.erb +2 -2
- data/vendor/plugins/images/app/views/admin/images/insert.html.erb +1 -1
- data/vendor/plugins/inquiries/app/models/inquiry.rb +3 -3
- data/vendor/plugins/inquiries/app/views/admin/inquiries/show.html.erb +1 -1
- data/vendor/plugins/inquiries/rails/init.rb +1 -1
- data/vendor/plugins/news/app/controllers/admin/news_items_controller.rb +1 -1
- data/vendor/plugins/news/app/controllers/news_items_controller.rb +1 -1
- data/vendor/plugins/news/app/models/news_item.rb +2 -2
- data/vendor/plugins/news/app/views/admin/news_items/_news_item.html.erb +1 -1
- data/vendor/plugins/news/app/views/admin/news_items/edit.html.erb +1 -1
- data/vendor/plugins/pages/app/controllers/admin/pages_controller.rb +13 -0
- data/vendor/plugins/pages/app/models/page_part.rb +3 -1
- data/vendor/plugins/pages/app/views/admin/page_dialogs/_page_link.html.erb +2 -2
- data/vendor/plugins/pages/app/views/admin/pages/_form.html.erb +2 -2
- data/vendor/plugins/pages/app/views/admin/pages/_page_part_field.html.erb +1 -1
- data/vendor/plugins/refinery/app/views/admin/_head.html.erb +3 -3
- data/vendor/plugins/refinery/app/views/admin/_menu.html.erb +3 -7
- data/vendor/plugins/refinery/app/views/shared/_menu.html.erb +1 -1
- data/vendor/plugins/refinery/app/views/shared/admin/_form_actions.html.erb +5 -3
- data/vendor/plugins/refinery/app/views/shared/admin/_image_picker.html.erb +1 -1
- data/vendor/plugins/refinery/app/views/shared/admin/_resource_picker.html.erb +0 -1
- data/vendor/plugins/refinery/lib/refinery.rb +9 -2
- data/vendor/plugins/refinery/lib/refinery/application_controller.rb +1 -1
- data/vendor/plugins/refinery/lib/refinery/deprecations.rb +46 -0
- data/vendor/plugins/refinery/lib/refinery/initializer.rb +20 -9
- data/vendor/plugins/refinery_dialogs/app/controllers/admin/dialogs_controller.rb +6 -5
- data/vendor/plugins/refinery_dialogs/app/views/admin/dialogs/show.html.erb +2 -2
- data/vendor/plugins/refinery_settings/app/models/refinery_setting.rb +41 -11
- data/vendor/plugins/refinery_settings/app/views/admin/refinery_settings/_form.html.erb +1 -1
- data/vendor/plugins/resources/app/controllers/admin/resources_controller.rb +1 -1
- data/vendor/plugins/resources/app/models/resource.rb +3 -3
- data/vendor/plugins/resources/app/views/admin/resources/_form.html.erb +2 -2
- data/vendor/plugins/resources/app/views/admin/resources/insert.html.erb +2 -2
- data/vendor/plugins/themes/app/helpers/themes_helper.rb +1 -1
- data/vendor/plugins/themes/lib/theme_server.rb +1 -1
- data/vendor/plugins/themes/rails/init.rb +26 -18
- metadata +10 -20
- data/Gemfile +0 -12
- data/public/javascripts/thickbox.js +0 -350
- data/public/stylesheets/refinery/thickbox.css +0 -165
- data/vendor/cache/aasm-2.1.3.gem +0 -0
- data/vendor/cache/actionmailer-2.3.5.gem +0 -0
- data/vendor/cache/actionpack-2.3.5.gem +0 -0
- data/vendor/cache/activerecord-2.3.5.gem +0 -0
- data/vendor/cache/activeresource-2.3.5.gem +0 -0
- data/vendor/cache/activesupport-2.3.5.gem +0 -0
- data/vendor/cache/friendly_id-2.3.1.gem +0 -0
- data/vendor/cache/hpricot-0.8.2.gem +0 -0
- data/vendor/cache/rack-1.0.1.gem +0 -0
- data/vendor/cache/rails-2.3.5.gem +0 -0
- data/vendor/cache/rake-0.8.7.gem +0 -0
- data/vendor/cache/rubyzip-0.9.1.gem +0 -0
- data/vendor/cache/slim_scrooge-1.0.3.gem +0 -0
- data/vendor/cache/will_paginate-2.3.11.gem +0 -0
@@ -1,350 +0,0 @@
|
|
1
|
-
/*
|
2
|
-
* Thickbox 3.1 - One Box To Rule Them All.
|
3
|
-
* By Cody Lindley (http://www.codylindley.com)
|
4
|
-
* Copyright (c) 2007 cody lindley
|
5
|
-
* Licensed under the MIT License: http://www.opensource.org/licenses/mit-license.php
|
6
|
-
*/
|
7
|
-
|
8
|
-
var tb_pathToImages = "/images/thickbox/";
|
9
|
-
|
10
|
-
/*!!!!!!!!!!!!!!!!! edit below this line at your own risk !!!!!!!!!!!!!!!!!!!!!!!*/
|
11
|
-
|
12
|
-
//on page load call tb_init
|
13
|
-
$(document).ready(function(){
|
14
|
-
tb_init('a.thickbox, area.thickbox, input.thickbox');//pass where to apply thickbox
|
15
|
-
imgLoader = new Image();// preload image
|
16
|
-
imgLoader.src = tb_pathToImages + "loadingAnimation.gif";
|
17
|
-
});
|
18
|
-
|
19
|
-
//add thickbox to href & area elements that have a class of .thickbox
|
20
|
-
function tb_init(domChunk){
|
21
|
-
$(domChunk).click(function(){
|
22
|
-
var t = this.title || this.name || this.innerHTML || null;
|
23
|
-
var a = this.href || this.alt;
|
24
|
-
var g = this.rel || false;
|
25
|
-
tb_show(t,a,g);
|
26
|
-
this.blur();
|
27
|
-
return false;
|
28
|
-
});
|
29
|
-
}
|
30
|
-
|
31
|
-
function tb_show(caption, url, imageGroup, ajax_loaded_callback) {//function called when the user clicks on a thickbox link
|
32
|
-
|
33
|
-
try {
|
34
|
-
if (typeof document.body.style.maxHeight === "undefined") {//if IE 6
|
35
|
-
$("body","html").css({height: "100%", width: "100%"});
|
36
|
-
$("html").css("overflow","hidden");
|
37
|
-
if (document.getElementById("TB_HideSelect") === null) {//iframe to hide select elements in ie6
|
38
|
-
$("body").append("<iframe id='TB_HideSelect'></iframe><div id='TB_overlay'></div><div id='TB_window'></div>");
|
39
|
-
$("#TB_overlay").click(tb_remove);
|
40
|
-
}
|
41
|
-
}else{//all others
|
42
|
-
if(document.getElementById("TB_overlay") === null){
|
43
|
-
$("body").append("<div id='TB_overlay'></div><div id='TB_window'></div>");
|
44
|
-
$("#TB_overlay").click(tb_remove);
|
45
|
-
}
|
46
|
-
}
|
47
|
-
|
48
|
-
if(tb_detectMacXFF()){
|
49
|
-
$("#TB_overlay").addClass("TB_overlayMacFFBGHack");//use png overlay so hide flash
|
50
|
-
}else{
|
51
|
-
$("#TB_overlay").addClass("TB_overlayBG");//use background and opacity
|
52
|
-
}
|
53
|
-
|
54
|
-
if(caption===null){caption="";}
|
55
|
-
$("body").append("<div id='TB_load'><img src='"+imgLoader.src+"' /></div>");//add loader to the page
|
56
|
-
$('#TB_load').show();//show loader
|
57
|
-
|
58
|
-
var baseURL;
|
59
|
-
if(url.indexOf("?")!==-1){ //ff there is a query string involved
|
60
|
-
baseURL = url.substr(0, url.indexOf("?"));
|
61
|
-
}
|
62
|
-
else {
|
63
|
-
baseURL = url;
|
64
|
-
}
|
65
|
-
|
66
|
-
var urlString = /\.jpg$|\.jpeg$|\.png$|\.gif$|\.bmp$/;
|
67
|
-
var urlType = baseURL.toLowerCase().match(urlString);
|
68
|
-
|
69
|
-
if(urlType == '.jpg' || urlType == '.jpeg' || urlType == '.png' || urlType == '.gif' || urlType == '.bmp')
|
70
|
-
{
|
71
|
-
//code to show images
|
72
|
-
TB_PrevCaption = "";
|
73
|
-
TB_PrevURL = "";
|
74
|
-
TB_PrevHTML = "";
|
75
|
-
TB_NextCaption = "";
|
76
|
-
TB_NextURL = "";
|
77
|
-
TB_NextHTML = "";
|
78
|
-
TB_imageCount = "";
|
79
|
-
TB_FoundURL = false;
|
80
|
-
if(imageGroup){
|
81
|
-
TB_TempArray = $("a[@rel="+imageGroup+"]").get();
|
82
|
-
for (TB_Counter = 0; ((TB_Counter < TB_TempArray.length) && (TB_NextHTML === "")); TB_Counter++) {
|
83
|
-
var urlTypeTemp = TB_TempArray[TB_Counter].href.toLowerCase().match(urlString);
|
84
|
-
if (!(TB_TempArray[TB_Counter].href == url)) {
|
85
|
-
if (TB_FoundURL) {
|
86
|
-
TB_NextCaption = TB_TempArray[TB_Counter].title;
|
87
|
-
TB_NextURL = TB_TempArray[TB_Counter].href;
|
88
|
-
TB_NextHTML = "<span id='TB_next'> <a href='#'>Next ></a></span>";
|
89
|
-
} else {
|
90
|
-
TB_PrevCaption = TB_TempArray[TB_Counter].title;
|
91
|
-
TB_PrevURL = TB_TempArray[TB_Counter].href;
|
92
|
-
TB_PrevHTML = "<span id='TB_prev'> <a href='#'>< Prev</a></span>";
|
93
|
-
}
|
94
|
-
} else {
|
95
|
-
TB_FoundURL = true;
|
96
|
-
TB_imageCount = "Image " + (TB_Counter + 1) +" of "+ (TB_TempArray.length);
|
97
|
-
}
|
98
|
-
}
|
99
|
-
}
|
100
|
-
|
101
|
-
imgPreloader = new Image();
|
102
|
-
imgPreloader.onload = function(){
|
103
|
-
imgPreloader.onload = null;
|
104
|
-
|
105
|
-
// Resizing large images - orginal by Christian Montoya edited by me.
|
106
|
-
var pagesize = tb_getPageSize();
|
107
|
-
var x = pagesize[0] - 150;
|
108
|
-
var y = pagesize[1] - 150;
|
109
|
-
var imageWidth = imgPreloader.width;
|
110
|
-
var imageHeight = imgPreloader.height;
|
111
|
-
if (imageWidth > x) {
|
112
|
-
imageHeight = imageHeight * (x / imageWidth);
|
113
|
-
imageWidth = x;
|
114
|
-
if (imageHeight > y) {
|
115
|
-
imageWidth = imageWidth * (y / imageHeight);
|
116
|
-
imageHeight = y;
|
117
|
-
}
|
118
|
-
} else if (imageHeight > y) {
|
119
|
-
imageWidth = imageWidth * (y / imageHeight);
|
120
|
-
imageHeight = y;
|
121
|
-
if (imageWidth > x) {
|
122
|
-
imageHeight = imageHeight * (x / imageWidth);
|
123
|
-
imageWidth = x;
|
124
|
-
}
|
125
|
-
}
|
126
|
-
// End Resizing
|
127
|
-
|
128
|
-
TB_WIDTH = imageWidth + 30;
|
129
|
-
TB_HEIGHT = imageHeight + 60;
|
130
|
-
$("#TB_window").append("<a href='' id='TB_ImageOff' title='Close'><img id='TB_Image' src='"+url+"' width='"+imageWidth+"' height='"+imageHeight+"' alt='"+caption+"'/></a>" + "<div id='TB_caption'>"+caption+"<div id='TB_secondLine'>" + TB_imageCount + TB_PrevHTML + TB_NextHTML + "</div></div><div id='TB_closeWindow'><a href='#' id='TB_closeWindowButton' title='Close'>close</a> or Esc Key</div>");
|
131
|
-
|
132
|
-
$("#TB_window .close_dialog").click(tb_remove);
|
133
|
-
|
134
|
-
if (!(TB_PrevHTML === "")) {
|
135
|
-
function goPrev(){
|
136
|
-
if($(document).unbind("click",goPrev)){$(document).unbind("click",goPrev);}
|
137
|
-
$("#TB_window").remove();
|
138
|
-
$("body").append("<div id='TB_window'></div>");
|
139
|
-
tb_show(TB_PrevCaption, TB_PrevURL, imageGroup);
|
140
|
-
return false;
|
141
|
-
}
|
142
|
-
$("#TB_prev").click(goPrev);
|
143
|
-
}
|
144
|
-
|
145
|
-
if (!(TB_NextHTML === "")) {
|
146
|
-
function goNext(){
|
147
|
-
$("#TB_window").remove();
|
148
|
-
$("body").append("<div id='TB_window'></div>");
|
149
|
-
tb_show(TB_NextCaption, TB_NextURL, imageGroup);
|
150
|
-
return false;
|
151
|
-
}
|
152
|
-
$("#TB_next").click(goNext);
|
153
|
-
|
154
|
-
}
|
155
|
-
|
156
|
-
document.onkeydown = function(e){
|
157
|
-
if (e == null) { // ie
|
158
|
-
keycode = event.keyCode;
|
159
|
-
} else { // mozilla
|
160
|
-
keycode = e.which;
|
161
|
-
}
|
162
|
-
if(keycode == 27){ // close
|
163
|
-
tb_remove();
|
164
|
-
} else if(keycode == 190){ // display previous image
|
165
|
-
if(!(TB_NextHTML == "")){
|
166
|
-
document.onkeydown = "";
|
167
|
-
goNext();
|
168
|
-
}
|
169
|
-
} else if(keycode == 188){ // display next image
|
170
|
-
if(!(TB_PrevHTML == "")){
|
171
|
-
document.onkeydown = "";
|
172
|
-
goPrev();
|
173
|
-
}
|
174
|
-
}
|
175
|
-
};
|
176
|
-
|
177
|
-
tb_position();
|
178
|
-
$("#TB_load").remove();
|
179
|
-
$("#TB_ImageOff").click(tb_remove);
|
180
|
-
$("#TB_window").css({display:"block"}); //for safari using css instead of show
|
181
|
-
};
|
182
|
-
|
183
|
-
imgPreloader.src = url;
|
184
|
-
}else{//code to show html
|
185
|
-
|
186
|
-
var queryString = url.replace(/^[^\?]+\??/,'');
|
187
|
-
var params = tb_parseQuery( queryString );
|
188
|
-
|
189
|
-
TB_WIDTH = (params['width']*1); + 30 || 630; //defaults to 630 if no paramaters were added to URL
|
190
|
-
TB_HEIGHT = (params['height']*1); + 40 || 440; //defaults to 440 if no paramaters were added to URL
|
191
|
-
ajaxContentW = params['auto_size_content'] ? 'auto' : TB_WIDTH - 30;
|
192
|
-
ajaxContentH = params['auto_size_content'] ? 'auto' : TB_HEIGHT - 45;
|
193
|
-
|
194
|
-
if(url.indexOf('TB_iframe') != -1 || url.indexOf('dialog=true') != -1){// either iframe or ajax window
|
195
|
-
urlNoQuery = url.split('TB_');
|
196
|
-
$("#TB_iframeContent").remove();
|
197
|
-
if(params['modal'] != "true"){//iframe no modal
|
198
|
-
$("#TB_window").append("<div id='TB_title'><div id='TB_ajaxWindowTitle'>"+caption+"</div><div id='TB_closeAjaxWindow'><a href='#' id='TB_closeWindowButton' class='close_dialog' title='Close'><img src='" + tb_pathToImages + "cross.png' alt='close'/></a></div></div><iframe frameborder='0' hspace='0' src='"+urlNoQuery[0]+"' id='TB_iframeContent' name='TB_iframeContent"+Math.round(Math.random()*1000)+"' onload='tb_showIframe()' style='width:"+(ajaxContentW + 30)+"px;height:"+(ajaxContentH + 17)+"px;' > </iframe>");
|
199
|
-
}else{//iframe modal
|
200
|
-
$("#TB_overlay").unbind();
|
201
|
-
if (params['titlebar'] == 'true') {
|
202
|
-
$("#TB_window").append("<div id='TB_title'><div id='TB_ajaxWindowTitle'>"+caption+"</div><div id='TB_closeAjaxWindow'><a href='#' id='TB_closeWindowButton' class='close_dialog' title='Close'><img src='" + tb_pathToImages + "cross.png' alt='close'/></a></div></div>");
|
203
|
-
}
|
204
|
-
$("#TB_window").append("<iframe frameborder='0' hspace='0' src='"+urlNoQuery[0]+"' id='TB_iframeContent' name='TB_iframeContent"+Math.round(Math.random()*1000)+"' onload='tb_showIframe()' style='width:"+(ajaxContentW + 30)+"px;height:"+(ajaxContentH + 17)+"px;'> </iframe>");
|
205
|
-
}
|
206
|
-
}else{// not an iframe, ajax
|
207
|
-
if($("#TB_window").css("display") != "block"){
|
208
|
-
if(params['modal'] != "true"){//ajax no modal
|
209
|
-
$("#TB_window").append("<div id='TB_title'><div id='TB_ajaxWindowTitle'>"+caption+"</div><div id='TB_closeAjaxWindow'><a href='#' id='TB_closeWindowButton' class='close_dialog'><img src='" + tb_pathToImages + "cross.png' alt='close'/></a></div></div><div id='TB_ajaxContent' style='width:"+ajaxContentW+"px;height:"+ajaxContentH+"px'></div>");
|
210
|
-
}else{//ajax modal
|
211
|
-
$("#TB_overlay").unbind();
|
212
|
-
if (params['titlebar'] == 'true') {
|
213
|
-
$("#TB_window").append("<div id='TB_title'><div id='TB_ajaxWindowTitle'>"+caption+"</div><div id='TB_closeAjaxWindow'><a href='#' id='TB_closeWindowButton' class='close_dialog' title='Close'><img src='" + tb_pathToImages + "cross.png' alt='close'/></a></div></div>");
|
214
|
-
}
|
215
|
-
$("#TB_window").append("<div id='TB_ajaxContent' class='TB_modal' style='width:"+ajaxContentW+"px;height:"+ajaxContentH+"px;'></div>");
|
216
|
-
}
|
217
|
-
}else{//this means the window is already up, we are just loading new content via ajax
|
218
|
-
$("#TB_ajaxContent")[0].style.width = ajaxContentW + (!params['auto_size_content'] ? "px" : "");
|
219
|
-
$("#TB_ajaxContent")[0].style.height = ajaxContentH + (!params['auto_size_content'] ? "px" : "");
|
220
|
-
$("#TB_ajaxContent")[0].scrollTop = 0;
|
221
|
-
$("#TB_ajaxWindowTitle").html(caption);
|
222
|
-
}
|
223
|
-
}
|
224
|
-
|
225
|
-
$("#TB_window .close_dialog").click(tb_remove);
|
226
|
-
|
227
|
-
if(url.indexOf('TB_inline') != -1){
|
228
|
-
$("#TB_ajaxContent").append($('#' + params['inlineId']).children());
|
229
|
-
$("#TB_window").unload(function () {
|
230
|
-
$('#' + params['inlineId']).append( $("#TB_ajaxContent").children() ); // move elements back when you're finished
|
231
|
-
});
|
232
|
-
tb_position();
|
233
|
-
$("#TB_load").remove();
|
234
|
-
$("#TB_window").css({display:"block"});
|
235
|
-
}else if(url.indexOf('TB_iframe') != -1 || url.indexOf('dialog=true') != -1){
|
236
|
-
tb_position();
|
237
|
-
if($.browser.safari){//safari needs help because it will not fire iframe onload
|
238
|
-
$("#TB_load").remove();
|
239
|
-
$("#TB_window").css({display:"block"});
|
240
|
-
}
|
241
|
-
}else{
|
242
|
-
$("#TB_ajaxContent").load(url += (url.indexOf("?") > -1 ? "&" : "?") + "random=" + (new Date().getTime()),function(){//to do a post change this load method
|
243
|
-
tb_position();
|
244
|
-
$("#TB_load").remove();
|
245
|
-
tb_init("#TB_ajaxContent a.thickbox");
|
246
|
-
$("#TB_window").css({display:"block"});
|
247
|
-
if (ajax_loaded_callback) {
|
248
|
-
ajax_loaded_callback();
|
249
|
-
}
|
250
|
-
});
|
251
|
-
}
|
252
|
-
|
253
|
-
}
|
254
|
-
|
255
|
-
if(!params['modal']){
|
256
|
-
document.onkeyup = function(e){
|
257
|
-
if (e == null) { // ie
|
258
|
-
keycode = event.keyCode;
|
259
|
-
} else { // mozilla
|
260
|
-
keycode = e.which;
|
261
|
-
}
|
262
|
-
if(keycode == 27){ // close
|
263
|
-
tb_remove();
|
264
|
-
}
|
265
|
-
};
|
266
|
-
}
|
267
|
-
else {
|
268
|
-
document.body.oldOverflow = document.body.style.overflow;
|
269
|
-
document.body.style.overflow = 'hidden';
|
270
|
-
}
|
271
|
-
|
272
|
-
if (params['draggable'])
|
273
|
-
{
|
274
|
-
$("#TB_window").draggable();
|
275
|
-
$("#TB_window").draggable('option', 'handle', '#TB_title');
|
276
|
-
}
|
277
|
-
|
278
|
-
$(document.onresize ? document : window).bind('resize', tb_position);
|
279
|
-
|
280
|
-
return 'TB_window';
|
281
|
-
|
282
|
-
} catch(e) {
|
283
|
-
//if (console) { console.log(e); }
|
284
|
-
//nothing here
|
285
|
-
}
|
286
|
-
}
|
287
|
-
|
288
|
-
//helper functions below
|
289
|
-
function tb_showIframe(){
|
290
|
-
$("#TB_load").remove();
|
291
|
-
$("#TB_window").css({display:"block"});
|
292
|
-
}
|
293
|
-
|
294
|
-
function tb_remove() {
|
295
|
-
$("#TB_imageOff").unbind("click");
|
296
|
-
$("#TB_window .close_dialog").unbind("click");
|
297
|
-
$("#TB_window").fadeOut("fast",function(){$('#TB_window,#TB_overlay,#TB_HideSelect').trigger("unload").unbind().remove();});
|
298
|
-
$("#TB_load").remove();
|
299
|
-
if (typeof document.body.style.maxHeight == "undefined") {//if IE 6
|
300
|
-
$("body","html").css({height: "auto", width: "auto"});
|
301
|
-
$("html").css("overflow","");
|
302
|
-
}
|
303
|
-
document.onkeydown = "";
|
304
|
-
document.onkeyup = "";
|
305
|
-
document.body.style.overflow = document.body.oldOverflow || "";
|
306
|
-
$(document.onresize ? document : window).unbind('resize', tb_position);
|
307
|
-
return false;
|
308
|
-
}
|
309
|
-
|
310
|
-
function tb_position() {
|
311
|
-
TB_HEIGHT = $("#TB_window").height();
|
312
|
-
TB_WIDTH = $("#TB_window").width();
|
313
|
-
$("#TB_window").css({marginLeft: '-' + parseInt((TB_WIDTH / 2),10) + 'px', width: TB_WIDTH + 'px'});
|
314
|
-
if ( !($.browser.msie && $.browser.version < 7)) { // take away IE6
|
315
|
-
marginTopAdjustment = parseInt((TB_HEIGHT / 2),10);
|
316
|
-
$("#TB_window").css({marginTop: '-' + marginTopAdjustment + 'px'});
|
317
|
-
topAdjustment = marginTopAdjustment + ((tb_getPageSize()[1] - TB_HEIGHT) / 2);
|
318
|
-
$("#TB_window").css({top: ((topAdjustment > marginTopAdjustment) ? topAdjustment : marginTopAdjustment) + "px"});
|
319
|
-
}
|
320
|
-
}
|
321
|
-
|
322
|
-
function tb_parseQuery ( query ) {
|
323
|
-
var Params = {};
|
324
|
-
if ( ! query ) {return Params;}// return empty object
|
325
|
-
var Pairs = query.split(/[;&]/);
|
326
|
-
for ( var i = 0; i < Pairs.length; i++ ) {
|
327
|
-
var KeyVal = Pairs[i].split('=');
|
328
|
-
if ( ! KeyVal || KeyVal.length != 2 ) {continue;}
|
329
|
-
var key = unescape( KeyVal[0] );
|
330
|
-
var val = unescape( KeyVal[1] );
|
331
|
-
val = val.replace(/\+/g, ' ');
|
332
|
-
Params[key] = val;
|
333
|
-
}
|
334
|
-
return Params;
|
335
|
-
}
|
336
|
-
|
337
|
-
function tb_getPageSize(){
|
338
|
-
var de = document.documentElement;
|
339
|
-
var w = window.innerWidth || self.innerWidth || (de&&de.clientWidth) || document.body.clientWidth;
|
340
|
-
var h = window.innerHeight || self.innerHeight || (de&&de.clientHeight) || document.body.clientHeight;
|
341
|
-
arrayPageSize = [w,h];
|
342
|
-
return arrayPageSize;
|
343
|
-
}
|
344
|
-
|
345
|
-
function tb_detectMacXFF() {
|
346
|
-
var userAgent = navigator.userAgent.toLowerCase();
|
347
|
-
if (userAgent.indexOf('mac') != -1 && userAgent.indexOf('firefox')!=-1) {
|
348
|
-
return true;
|
349
|
-
}
|
350
|
-
}
|
@@ -1,165 +0,0 @@
|
|
1
|
-
/* ----------------------------------------------------------------------------------------------------------------*/
|
2
|
-
/* ---------->>> global settings needed for thickbox <<<-----------------------------------------------------------*/
|
3
|
-
/* ----------------------------------------------------------------------------------------------------------------*/
|
4
|
-
/*
|
5
|
-
*{padding: 0; margin: 0;}
|
6
|
-
*/
|
7
|
-
|
8
|
-
/* ----------------------------------------------------------------------------------------------------------------*/
|
9
|
-
/* ---------->>> thickbox specific link and font settings <<<------------------------------------------------------*/
|
10
|
-
/* ----------------------------------------------------------------------------------------------------------------*/
|
11
|
-
#TB_window {
|
12
|
-
font: 12px Arial, Helvetica, sans-serif;
|
13
|
-
color: #333333;
|
14
|
-
}
|
15
|
-
|
16
|
-
#TB_secondLine {
|
17
|
-
font: 10px Arial, Helvetica, sans-serif;
|
18
|
-
color:#666666;
|
19
|
-
}
|
20
|
-
|
21
|
-
#TB_window a:link {color: #666666;}
|
22
|
-
#TB_window a:visited {color: #666666;}
|
23
|
-
#TB_window a:hover {color: #000;}
|
24
|
-
#TB_window a:active {color: #666666;}
|
25
|
-
#TB_window a:focus{color: #666666;}
|
26
|
-
|
27
|
-
/* ----------------------------------------------------------------------------------------------------------------*/
|
28
|
-
/* ---------->>> thickbox settings <<<-----------------------------------------------------------------------------*/
|
29
|
-
/* ----------------------------------------------------------------------------------------------------------------*/
|
30
|
-
#TB_overlay {
|
31
|
-
position: fixed;
|
32
|
-
z-index:100;
|
33
|
-
top: 0px;
|
34
|
-
left: 0px;
|
35
|
-
height:100%;
|
36
|
-
width:100%;
|
37
|
-
}
|
38
|
-
|
39
|
-
.TB_overlayMacFFBGHack {background: url(/images/thickbox/macFFBgHack.png) repeat;}
|
40
|
-
.TB_overlayBG {
|
41
|
-
background-color:#000;
|
42
|
-
filter:alpha(opacity=75);
|
43
|
-
-moz-opacity: 0.75;
|
44
|
-
opacity: 0.75;
|
45
|
-
}
|
46
|
-
|
47
|
-
* html #TB_overlay { /* ie6 hack */
|
48
|
-
position: absolute;
|
49
|
-
height: expression(document.body.scrollHeight > document.body.offsetHeight ? document.body.scrollHeight : document.body.offsetHeight + 'px');
|
50
|
-
}
|
51
|
-
|
52
|
-
#TB_window {
|
53
|
-
position: fixed;
|
54
|
-
background: #ffffff;
|
55
|
-
z-index: 102;
|
56
|
-
color:#000000;
|
57
|
-
display:none;
|
58
|
-
border: 4px solid #525252;
|
59
|
-
text-align:left;
|
60
|
-
top:50%;
|
61
|
-
left:50%;
|
62
|
-
}
|
63
|
-
|
64
|
-
* html #TB_window { /* ie6 hack */
|
65
|
-
position: absolute;
|
66
|
-
margin-top: expression(0 - parseInt(this.offsetHeight / 2) + (TBWindowMargin = document.documentElement && document.documentElement.scrollTop || document.body.scrollTop) + 'px');
|
67
|
-
}
|
68
|
-
|
69
|
-
#TB_window img#TB_Image {
|
70
|
-
display:block;
|
71
|
-
margin: 15px 0 0 15px;
|
72
|
-
border-right: 1px solid #ccc;
|
73
|
-
border-bottom: 1px solid #ccc;
|
74
|
-
border-top: 1px solid #666;
|
75
|
-
border-left: 1px solid #666;
|
76
|
-
}
|
77
|
-
|
78
|
-
#TB_caption{
|
79
|
-
height:25px;
|
80
|
-
padding:7px 30px 10px 25px;
|
81
|
-
float:left;
|
82
|
-
}
|
83
|
-
|
84
|
-
#TB_closeWindow{
|
85
|
-
height:25px;
|
86
|
-
padding:11px 25px 10px 0;
|
87
|
-
float:right;
|
88
|
-
}
|
89
|
-
|
90
|
-
#TB_closeAjaxWindow{
|
91
|
-
padding:7px 10px 5px 0;
|
92
|
-
margin-bottom:1px;
|
93
|
-
text-align:right;
|
94
|
-
float:right;
|
95
|
-
}
|
96
|
-
|
97
|
-
#TB_ajaxWindowTitle{
|
98
|
-
float:left;
|
99
|
-
padding:7px 0 5px 10px;
|
100
|
-
margin-bottom:1px;
|
101
|
-
}
|
102
|
-
|
103
|
-
#TB_title{
|
104
|
-
background-color:#e8e8e8;
|
105
|
-
height:27px;
|
106
|
-
}
|
107
|
-
|
108
|
-
#TB_ajaxContent{
|
109
|
-
clear:both;
|
110
|
-
padding:2px 15px 15px 15px;
|
111
|
-
overflow:auto;
|
112
|
-
text-align:left;
|
113
|
-
line-height:1.4em;
|
114
|
-
}
|
115
|
-
|
116
|
-
#TB_ajaxContent.TB_modal{
|
117
|
-
padding:15px;
|
118
|
-
}
|
119
|
-
|
120
|
-
#TB_ajaxContent p{
|
121
|
-
padding:5px 0px 5px 0px;
|
122
|
-
}
|
123
|
-
|
124
|
-
#TB_load{
|
125
|
-
position: fixed;
|
126
|
-
display:none;
|
127
|
-
height:13px;
|
128
|
-
width:208px;
|
129
|
-
z-index:103;
|
130
|
-
top: 50%;
|
131
|
-
left: 50%;
|
132
|
-
margin: -6px 0 0 -104px; /* -height/2 0 0 -width/2 */
|
133
|
-
}
|
134
|
-
|
135
|
-
* html #TB_load { /* ie6 hack */
|
136
|
-
position: absolute;
|
137
|
-
margin-top: expression(0 - parseInt(this.offsetHeight / 2) + (TBWindowMargin = document.documentElement && document.documentElement.scrollTop || document.body.scrollTop) + 'px');
|
138
|
-
}
|
139
|
-
|
140
|
-
#TB_HideSelect{
|
141
|
-
z-index:99;
|
142
|
-
position:fixed;
|
143
|
-
top: 0;
|
144
|
-
left: 0;
|
145
|
-
background-color:#fff;
|
146
|
-
border:none;
|
147
|
-
filter:alpha(opacity=0);
|
148
|
-
-moz-opacity: 0;
|
149
|
-
opacity: 0;
|
150
|
-
height:100%;
|
151
|
-
width:100%;
|
152
|
-
}
|
153
|
-
|
154
|
-
* html #TB_HideSelect { /* ie6 hack */
|
155
|
-
position: absolute;
|
156
|
-
height: expression(document.body.scrollHeight > document.body.offsetHeight ? document.body.scrollHeight : document.body.offsetHeight + 'px');
|
157
|
-
}
|
158
|
-
|
159
|
-
#TB_iframeContent{
|
160
|
-
clear:both;
|
161
|
-
border:none;
|
162
|
-
margin-bottom:-1px;
|
163
|
-
margin-top:1px;
|
164
|
-
_margin-bottom:1px;
|
165
|
-
}
|