From d2583e0a942542c0f1ea6a8cdc5dd8908c50b577 Mon Sep 17 00:00:00 2001 From: unknown Date: Tue, 2 Aug 2011 19:58:05 +0300 Subject: [PATCH] fixed some bugs --- .../interactive/Anyembed.wgt/js/ubw-main.js | 26 +- .../interactive/Calculator.wgt/js/ubw-main.js | 20 +- .../interactive/GeoInfo.wgt/GeoInfo.html | 362 ++++++------- .../interactive/GeoInfo.wgt/css/GeoInfo.css | 4 + .../library/interactive/GeoInfo.wgt/icon.png | Bin 4804 -> 5303 bytes .../interactive/GeoInfo.wgt/js/GeoInfo.js | 12 +- .../interactive/GeoInfo.wgt/js/soapclient.js | 2 +- .../interactive/Html.wgt/images/style.css | 2 + .../library/interactive/Html.wgt/index.html | 3 +- .../Html.wgt/markitup/sets/html/set.js | 2 +- .../Html.wgt/markitup/sets/html/style.css | 58 +-- .../Html.wgt/markitup/templates/preview.css | 1 + .../interactive/Notes.wgt/css/ubwidget.css | 2 +- .../interactive/Notes.wgt/js/ubw-main.js | 101 ++-- .../interactive/Stopwatch.wgt/js/ubw-main.js | 490 ++++++++++-------- .../interactive/VideoPicker.wgt/index.html | 126 ++--- .../VideoPicker.wgt/locales/en/error.html | 2 +- .../interactive/WebBrowser.wgt/index.html | 146 ++++-- 18 files changed, 724 insertions(+), 635 deletions(-) diff --git a/resources/library/interactive/Anyembed.wgt/js/ubw-main.js b/resources/library/interactive/Anyembed.wgt/js/ubw-main.js index ad76065d..91a1632f 100644 --- a/resources/library/interactive/Anyembed.wgt/js/ubw-main.js +++ b/resources/library/interactive/Anyembed.wgt/js/ubw-main.js @@ -38,8 +38,8 @@ function init(){ }); //FIT WIDGET FRAME ON LAUNCH... - if(window.uniboard){ - window.uniboard.resize($("#ubwidget").width()-15,85); + if(window.sankore){ + window.sankore.resize($("#ubwidget").width()-15,85); } searchWrap.append(inputBox) @@ -50,21 +50,27 @@ function init(){ submit.click(function(){ $("#ubwidget").append(loadWindow) embed = inputBox.val(); + ////////////!!!1///////// ïîïðîáîâàòü ñ ðåàäè searchWrap.hide(); loadWindow.append(embed); - - if(window.uniboard){ - window.uniboard.resize($(document).width(),$(document).height()); - window.uniboard.setPreference("embed", escape(embed)); - } + //alert($("#ubwidget").html()); + $("#ubwidget embed").attr("wmode", "transparent"); + var ubwidget_html = $("#ubwidget").html(); + alert(ubwidget_html); + setTimeOut(alert); + $("#ubwidget").empty().html(ubwidget_html); + if(window.sankore){ + window.sankore.resize($(document).width(),$(document).height()); + window.sankore.setPreference("embed", escape(embed)); + } }); - if(window.uniboard){ + if(window.sankore){ - if(window.uniboard.preferenceKeys().length != 0){ + if(window.sankore.preferenceKeys().length != 0){ - var loadEmbed = unescape(window.uniboard.preference("embed")); + var loadEmbed = unescape(window.sankore.preference("embed")); inputBox.val(loadEmbed); submit.trigger("click"); } diff --git a/resources/library/interactive/Calculator.wgt/js/ubw-main.js b/resources/library/interactive/Calculator.wgt/js/ubw-main.js index 44c86b95..23dc7f29 100644 --- a/resources/library/interactive/Calculator.wgt/js/ubw-main.js +++ b/resources/library/interactive/Calculator.wgt/js/ubw-main.js @@ -26,8 +26,8 @@ function init(){ backgroundImage:"url(images/back.png)", width:328 }); - if(window.uniboard){ - window.uniboard.setPreference('historyTab', "visible"); + if(window.sankore){ + window.sankore.setPreference('historyTab', "visible"); }; }, function(){ @@ -37,8 +37,8 @@ function init(){ backgroundImage:"url(images/back_small.png)", width:160 }); - if(window.uniboard){ - window.uniboard.setPreference('historyTab', "hidden"); + if(window.sankore){ + window.sankore.setPreference('historyTab', "hidden"); }; } ) @@ -200,9 +200,9 @@ function init(){ .append(historyPanel) .append(keysPanel); - if(window.uniboard){ - historyTxt = window.uniboard.preference('historyTxt', historyTxt); - var ht = window.uniboard.preference('historyTab', "hidden"); + if(window.sankore){ + historyTxt = window.sankore.preference('historyTxt', historyTxt); + var ht = window.sankore.preference('historyTab', "hidden"); $("#historyBox").val(historyTxt); if(ht === "visible"){ historyTab.trigger("click"); @@ -210,7 +210,7 @@ function init(){ } function resizeWidget(w, h){ - window.uniboard.resize(w+2, h+2); + window.sankore.resize(w+2, h+2); $("#indicator").remove(); var indicator = $("
") .css({ @@ -238,8 +238,8 @@ function compute(){ displayTrunk = ""; historyTrunk = ""; - if(window.uniboard){ - window.uniboard.setPreference('historyTxt', $("#historyBox").val()); + if(window.sankore){ + window.sankore.setPreference('historyTxt', $("#historyBox").val()); }; lastHistory = $("#historyBox").val(); diff --git a/resources/library/interactive/GeoInfo.wgt/GeoInfo.html b/resources/library/interactive/GeoInfo.wgt/GeoInfo.html index bb934dd7..d3559a9d 100644 --- a/resources/library/interactive/GeoInfo.wgt/GeoInfo.html +++ b/resources/library/interactive/GeoInfo.wgt/GeoInfo.html @@ -1013,11 +1013,11 @@ Comparer les pays: - - - - - + + + + +
@@ -1025,1061 +1025,1061 @@
Maroc
Capitale: Rabat
- +
Algerie
Capitale: Alger
- +
Tunisie
Capitale: Tunis
- +
Libye
Capitale: Tripoli
- +
Egypte
Capitale: Le Caire
- +
Sahara occidental
Capitale:
- +
Mauritanie
Capitale: Nouakchott
- +
Mali
Capitale: Bamako
- +
Niger
Capitale: Niamey
- +
Tchad
Capitale: Ndjamena
- +
Soudan
Capitale: Khartoum
- +
Erythree
Capitale: Asmara
- +
Djibouti
Capitale: Djibouti
- +
Ethiopie
Capitale: Addis Abeba
- +
Somalie
Capitale: Mogadiscio
- +
Kenya
Capitale: Nairobi
- +
Ouganda
Capitale: Kampala
- +
Republique democratique du Congo
Capitale: Kinshasa
- +
Republique centrafricaine
Capitale: Bangui
- +
Cameroun
Capitale: Yaounde
- +
Nigeria
Capitale: Abuja
- +
Benin
Capitale: Porto Novo
- +
Togo
Capitale: Lome
- +
Ghana
Capitale: Accra
- +
Cote d'Ivoire
Capitale: Yamoussoukro
- +
Burkina Faso
Capitale: Ouagadougou
- +
Liberia
Capitale: Monravia
- +
Sierra Leone
Capitale: Freetown
- +
Guinee
Capitale: Conakry
- +
Guinee-Bissau
Capitale: Bissau
- +
Senegal
Capitale: Dakar
- +
Gambie
Capitale: Banjul
- +
Rwanda
Capitale: Kigali
- +
Burundi
Capitale: Bujumbura
- +
Republique du Congo
Capitale: Brazzaville
- +
Gabon
Capitale: Libreville
- +
Guinee Equatoriale
Capitale: Malabo
- +
Tanzanie
Capitale: Dodoma
- +
Malawi
Capitale: Lilongwe
- +
Zambie
Capitale: Lusaka
- +
Angola
Capitale: Luanda
- +
Mozambique
Capitale: Maputo
- +
Zimbabwe
Capitale: Harare
- +
Botswana
Capitale: Gaborone
- +
Namibie
Capitale: Windhoec
- +
Afrique du Sud
Capitale: Pretoria
- +
Lesotho
Capitale: Maseru
- +
Swaziland
Capitale: Mbabane
- +
Madagascar
Capitale: Antananarivo
- +
Argentine
Capitale: Buenos Aires
- +
Chili
Capitale: Santiago
- +
Uruguay
Capitale: Montevideo
- +
Paraguay
Capitale: Asuncion
- +
Bolivie
Capitale: La Paz
- +
Bresil
Capitale: Brasilia
- +
Perou
Capitale: Lima
- +
Equateur
Capitale: Quito
- +
Colombie
Capitale: Bogota
- +
Venezuela
Capitale: Caracas
- +
Guyana
Capitale: Georgetown
- +
Suriname
Capitale: Paramaribo
- +
Guyane
Capitale: Paris
- +
Canada
Capitale: Ottawa
- +
Groenland
Capitale: Nuuk
- +
Etats-Unis d'Amerique
Capitale: Washington DC
- +
Mexique
Capitale: Mexico
- +
Cuba
Capitale: La Havane
- +
Haiti
Capitale: Port-au-Prince
- +
Republique dominicaine
Capitale: Saint-Domingue
- +
Jamaique
Capitale: Kingston
- +
Bahamas
Capitale: Nassau
- +
Guatemala
Capitale: Guatemala
- +
Belize
Capitale: Belmopan
- +
El Salvador
Capitale: San Salvador
- +
Honduras
Capitale: Tegucigalpa
- +
Nicaragua
Capitale: Managua
- +
Costa-Rica
Capitale: San Jose
- +
Panama
Capitale: Panama
- +
Australie
Capitale: Canberra
- +
Nouvelle-Zelande
Capitale: Wellington
- +
Papouasie-Nouvelle-Guinee
Capitale: Port Moresby
- +
Indonesie
Capitale: Jakarta
- +
Iles Salomon
Capitale: Honiara
- +
Vanuatu
Capitale: Port-Vila
- +
Nouvelle-Caledonie
Capitale: Paris
- +
Albanie
Capitale: Tirana
- +
Allemagne
Capitale: Berlin
- +
Armenie
Capitale: Erevan
- +
Autriche
Capitale: Vienne
- +
Azerbaidjan
Capitale: Bakou
- +
Belgique
Capitale: Bruxelles
- +
Belarus
Capitale: Minsk
- +
Bosnie
Capitale: Sarajevo
- +
Bulgarie
Capitale: Sofia
- +
Chypre
Capitale: Nicosie
- +
Croatie
Capitale: Zagreb
- +
Danemark
Capitale: Copenhague
- +
Espagne
Capitale: Madrid
- +
Estonie
Capitale: Tallinn
- +
Finlande
Capitale: Helsinki
- +
France
Capitale: Paris
- +
Georgie
Capitale: Tbilissi
- +
Grece
Capitale: Athenes
- +
Hongrie
Capitale: Budapest
- +
Irlande
Capitale: Dublin
- +
Islande
Capitale: Reykjavik
- +
Italie
Capitale: Rome
- +
Lettonie
Capitale: Riga
- +
Liechtenstein
Capitale: Vaduz
- +
Lituanie
Capitale: Vilnius
- +
Luxembourg
Capitale: Luxembourg
- +
Macedoine
Capitale: Skopje
- +
Malte
Capitale: La Valette
- +
Moldavie
Capitale: Chisinau
- +
Monaco
Capitale: Monaco
- +
Montenegro
Capitale: Podaorica
- +
Norvege
Capitale: Oslo
- +
Pays-Bas
Capitale: Amsterdam
- +
Pologne
Capitale: Varsovie
- +
Portugal
Capitale: Lisbonne
- +
Republique tcheque
Capitale: Prague
- +
Roumanie
Capitale: Bucarest
- +
Royaume-Uni
Capitale: Londres
- +
Saint-Marin
Capitale: Saint-Marin
- +
Serbie
Capitale: Belgrade
- +
Slovaquie
Capitale: Bratislava
- +
Slovenie
Capitale: Ljubljana
- +
Suede
Capitale: Stockholm
- +
Suisse
Capitale: Berne
- +
Turquie
Capitale: Ankara
- +
Ukraine
Capitale: Kiev
- +
Vatican
Capitale: Cite du Vatican
- +
Afghanistan
Capitale: Kaboul
- +
Arabie Saoudite
Capitale: Riyad
- +
Bahrein
Capitale: Manama
- +
Bangladesh
Capitale: Dhaka
- +
Bhoutan
Capitale: Thimphou
- +
Brunei
Capitale: Bandar Seri Begawan
- +
Cambodge
Capitale: Phnom Penh
- +
Chine
Capitale: Pekin
- +
Coree du Nord
Capitale: Pyongyang
- +
Coree du Sud
Capitale: Seoul
- +
Emirats arabes unis
Capitale: Abou Dabi
- +
Inde
Capitale: New Delhi
- +
Indonesie
Capitale: Jakarta
- +
Iran
Capitale: Teheran
- +
Iraq
Capitale: Bagdad
- +
Israel
Capitale: Jerusalem
- +
Japon
Capitale: Tokyo
- +
Jordanie
Capitale: Amman
- +
Kazakhstan
Capitale: Astana
- +
Kirghizistan
Capitale: Bichkek
- +
Koweit
Capitale: Koweit
- +
Laos
Capitale: Vientiane
- +
Liban
Capitale: Beyrouth
- +
Malaisie
Capitale: Kuala Lumpur
- +
Maldives
Capitale: Male
- +
Mongolie
Capitale: Oulan-Bator
- +
Myanmar
Capitale: Naypyidaw
- +
Nepal
Capitale: Katmandou
- +
Oman
Capitale: Mascate
- +
Ouzbekistan
Capitale: Tachkent
- +
Pakistan
Capitale: Islamabad
- +
Philippines
Capitale: Manille
- +
Qatar
Capitale: Doha
- +
Russie
Capitale: Moscou
- +
Singapour
Capitale: Singapour
- +
Sri Lanka
Capitale: Colombo
- +
Syrie
Capitale: Damas
- +
Tadjikistan
Capitale: Douchanbe
- +
Thailande
Capitale: Bangkok
- +
Timor-oriental
Capitale: Dili
- +
Turkmenistan
Capitale: Achgabat
- +
Viet Nam
Capitale: Hanoi
- +
Yemen
Capitale: Sanaa
- +
diff --git a/resources/library/interactive/GeoInfo.wgt/css/GeoInfo.css b/resources/library/interactive/GeoInfo.wgt/css/GeoInfo.css index 65c9d25b..6bc7a4d4 100644 --- a/resources/library/interactive/GeoInfo.wgt/css/GeoInfo.css +++ b/resources/library/interactive/GeoInfo.wgt/css/GeoInfo.css @@ -1,3 +1,7 @@ +body { + background-color: white; +} + .styleDiv { height:250px; diff --git a/resources/library/interactive/GeoInfo.wgt/icon.png b/resources/library/interactive/GeoInfo.wgt/icon.png index 881af2841e170ad0d62783514b738bce9eb012d3..b66223b5d31f539db835602ce33a0eba23dd14f3 100644 GIT binary patch literal 5303 zcmZ`-S2P>|(-pn07A5MgPDJl@v3iIa2^Ndh%d*z4UZO^#ClL}v?_G431c_+TdoR&~ z)k2gn-}n6g4|ndFIWu$aIdkUa#v2)GQ<1ZfFPjC{;~OgK}!5D%AJ*1;^EPc z=|a@ZFdq&+2KZU`zUd1)TiP>t)F`9>c2jc(lR!nhUc)Q~$fEbaPm2d-tbk?gbi$eO z9}}~EPNpaAPtN!NPW?jIQxiq_EsEVCEh?m5+~$anTYt*yprh;J_qFk2-CU}N?%N*l zm7;dw&D%2cUb$7%@5-{@Ci^5@5&$`(3<@@~$M{~S2`Esea>YLVZ?h!;GEd*krSvyRbi&rF>{hPc>;kj z68wmGeh2AR8Iq&V0CIr}CvwJ^+N7lmKdJKT|1zrKXy&V|CH9*i{qdbn!E6v;TFp&5!rvy84}`EL0?RAK1WcuvEO^*{X& zqK0uJ_CpQQ_bsD4hz^b2;KXiH%3C7#$4>e`MC8V`V%tgAYKlmDoUXqe)LhBL>-{=Rl>}^g!1*G*|k@Gsu@hT?8 ziGm_Ue~J)lKZ%4{J6=hDbe9X-n-ylQf0fm@1o=i;D^iy@o8=@qDf{Nasa<=NG%vl! z)0L;rQDN!fVPD%3>w{{VX;AQzl;en3u*J>GuTYCTy@6wB5NGW}Lt+hh=0hUA`#pA7 z5gd;b!grxvdV-`IDJP?Rsds;uFbzWQts++TRv9e;e0uj|NdWvKgZV-> zny5O3G^~o)ylR&8_;j-O76Af!hEke7X4`YF>Stut-yvRo`J?^O3C0VDjH(z_+3M4L z@P1flE&2`=I!;s)&UrUrp>w^L;emG07*GElLb0=O8stysyl0tr=fl-f&drnEnzWI2 z0a8?jJpcQ>-(Xh7!DU}h{aZ*2fv{*C1&1h<|2g5^v)KcK)6-XWoF^LXT` zUMg%AeDP6TifWJoR-V}fqP)G!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VL#8Io@E^`Mg_lT>_ z$8pq&Ju}FWCb$u(B^fTm-gsawOs8gb0uG*U*2Ddg-Cpl>6PGClN*q|>F4C3G0mZdAt4gq?x~8SvNo)!CspRAqyR0 zRjzd-@LOh0hPrw3(sZYvdb022oVe4#&Q5eMxIF=3Ykro?JZ~`)2jxES+f?2wcq0oR zT|(AIl=DSun#3Px+dWR%+Qr0*kKCo@2i5EgBdVsayUuZz0L1o|eg8#C)5KcS++`8v_piP>pt~fNI&7giOKg zezhO8?PpFBmg$EXiWBgyn(SvmQzg03cHoY-KquF;P9E}F+|gv8wn*IP{^k11Dtv9f z`G;bb)$H?St5d?m1jEieg|=tD3^sI+ul96xw>){%toKkK&i^o>D>ZgJg z;>r?8cWdn*fvnlD35Z+w`WYQo>4ptYjSuR@a}#=FldSF9M9siGEMV)hWVEN`UybQ+ zvy~}Xr|}h|fbRKwo>yea5={IQX?VJk(QiB#gdS#Y(33*n6W(Rv#76@rZl z{)CPIc94LfVl-R-df@!~N7f&n0e{tKGeW-3M{DgpyD+(R{huwR9@gWcYBnuoDei~> zk!&vnf~~@g4_i9wp3@dq91vI?Y7~qltg^bKyZ~Mg1m1fq*>{(iwXZ0_hOv>fMyOHl zMnBldOoqWCF=g_~K}DT2hui;687`T zlN*zqOpN5$m;j1_-37;tIFpQsFgdijE&DgFg%M6CAkVPC`Xnbj_4uL7RKf53{{66_ z_CP}TCf7pYsIh46=jO)$%HP9vlM}jQMT>>nyZE2zt8uX6_r`^R=jQ9)?>kx@&peGM zzj&~s5ufPN{C)WG2f^&Q>)yli2SVc;xPqGH#Im-w^8aYjyZmGJ|6XU%hRhEnPJU(X VA_S" + + "xmlns:soap=\"http://schemas.xmlsoap.org/soap/envelope/\" " + "xmlns:ser=\"" + ns + "\">" + "" + "" + parameters.toXml() + diff --git a/resources/library/interactive/Html.wgt/images/style.css b/resources/library/interactive/Html.wgt/images/style.css index 05d012a9..52de70b1 100644 --- a/resources/library/interactive/Html.wgt/images/style.css +++ b/resources/library/interactive/Html.wgt/images/style.css @@ -1,7 +1,9 @@ body { font: 13px "Trebuchet MS", Arial, Verdana; padding-top:0px; + color: gray; } + a { text-decoration:none; color:#3C769D; diff --git a/resources/library/interactive/Html.wgt/index.html b/resources/library/interactive/Html.wgt/index.html index f5367dec..86d58ba5 100644 --- a/resources/library/interactive/Html.wgt/index.html +++ b/resources/library/interactive/Html.wgt/index.html @@ -10,9 +10,8 @@ - - + diff --git a/resources/library/interactive/Html.wgt/markitup/sets/html/set.js b/resources/library/interactive/Html.wgt/markitup/sets/html/set.js index 6ae74c3d..e1a5504e 100644 --- a/resources/library/interactive/Html.wgt/markitup/sets/html/set.js +++ b/resources/library/interactive/Html.wgt/markitup/sets/html/set.js @@ -34,6 +34,6 @@ mySettings = { {name:'Link', key:'L', openWith:'', closeWith:'', placeHolder:'Your text to link...' }, {separator:'---------------' }, //{name:'Editor', className:'clean', replaceWith:function() { $('textarea').show(); $('iframe').remove();} }, - {name:'Preview', className:'preview', call:'preview'} + {name:'', className:'preview', call:'preview'} ] } \ No newline at end of file diff --git a/resources/library/interactive/Html.wgt/markitup/sets/html/style.css b/resources/library/interactive/Html.wgt/markitup/sets/html/style.css index aa8db144..c22ef4de 100644 --- a/resources/library/interactive/Html.wgt/markitup/sets/html/style.css +++ b/resources/library/interactive/Html.wgt/markitup/sets/html/style.css @@ -3,95 +3,71 @@ // By Jay Salvat - http://markitup.jaysalvat.com/ // ------------------------------------------------------------------*/ .markItUp .markItUpButton1 a { - position:static; - margin-left:5px; background-image:url(images/h1.png); + background-repeat:no-repeat; } -.markItUp .markItUpButton2 a { - position:static; - +.markItUp .markItUpButton2 a { background-image:url(images/h2.png); + background-repeat:no-repeat; } .markItUp .markItUpButton3 a { - position:static; - background-image:url(images/h3.png); + background-repeat:no-repeat; } .markItUp .markItUpButton4 a { - position:static; - background-image:url(images/h4.png); + background-repeat:no-repeat; } .markItUp .markItUpButton5 a { - position:static; - + background-repeat:no-repeat; background-image:url(images/h5.png); } .markItUp .markItUpButton6 a { - position:static; - + background-repeat:no-repeat; background-image:url(images/h6.png); } .markItUp .markItUpButton7 a { - position:static; - + background-repeat:no-repeat; background-image:url(images/paragraph.png); } .markItUp .markItUpButton8 a { - position:static; - + background-repeat:no-repeat; background-image:url(images/bold.png); } .markItUp .markItUpButton9 a { - position:static; - + background-repeat:no-repeat; background-image:url(images/italic.png); } .markItUp .markItUpButton10 a { - position:static; - + background-repeat:no-repeat; background-image:url(images/stroke.png); } .markItUp .markItUpButton11 a { - position:static; - + background-repeat:no-repeat; background-image:url(images/list-bullet.png); } .markItUp .markItUpButton12 a { - position:static; - + background-repeat:no-repeat; background-image:url(images/list-numeric.png); } .markItUp .markItUpButton13 a { - position:static; - + background-repeat:no-repeat; background-image:url(images/list-item.png); } .markItUp .markItUpButton14 a { - position:static; - + background-repeat:no-repeat; background-image:url(images/picture.png); } .markItUp .markItUpButton15 a { - position:static; - + background-repeat:no-repeat; background-image:url(images/link.png); } -.markItUp .clean a { - position:static; - - margin-top:-2px; - width:32px; - height:20px; - background-image:url(images/clean.png); -} .markItUp .preview a { - position:static; - + background-repeat:no-repeat; margin-top:-2px; width:46px; height:20px; diff --git a/resources/library/interactive/Html.wgt/markitup/templates/preview.css b/resources/library/interactive/Html.wgt/markitup/templates/preview.css index 05eb4e3b..000d9ee4 100644 --- a/resources/library/interactive/Html.wgt/markitup/templates/preview.css +++ b/resources/library/interactive/Html.wgt/markitup/templates/preview.css @@ -1,3 +1,4 @@ body { font:70% Verdana, Arial, Helvetica, sans-serif; + color: orange; } \ No newline at end of file diff --git a/resources/library/interactive/Notes.wgt/css/ubwidget.css b/resources/library/interactive/Notes.wgt/css/ubwidget.css index 0a9d155f..d0d52396 100644 --- a/resources/library/interactive/Notes.wgt/css/ubwidget.css +++ b/resources/library/interactive/Notes.wgt/css/ubwidget.css @@ -41,7 +41,7 @@ body{ .stickytitle{ background-color: transparent; min-width: 10px; - max-width: 60%; + max-width: 70%; width: 100%; padding-top: 4px; height: 20px; diff --git a/resources/library/interactive/Notes.wgt/js/ubw-main.js b/resources/library/interactive/Notes.wgt/js/ubw-main.js index b5ff1e8d..555fbb0b 100644 --- a/resources/library/interactive/Notes.wgt/js/ubw-main.js +++ b/resources/library/interactive/Notes.wgt/js/ubw-main.js @@ -1,10 +1,11 @@ function init(){ var ubwidget = $("#ubwidget").ubwidget({ - width:300, + width:360, height:240 }); + var checkMinimize = false; var text = ""; var winwidth; var minimizedHeight; @@ -12,18 +13,18 @@ function init(){ var scroll = false; var defaultFontSize = 35; var currentFontSize = defaultFontSize; - var header = $(''); - var fontUp = $(''); - var fontDown = $(''); - var minimize = $(''); - var maximize = $(''); + var header = $(''); + var fontUp = $(''); + var fontDown = $(''); + var minimize = $(''); + var maximize = $(''); var title = $(''); var textField = $('
'); var shadow = $("
 
") .appendTo("body"); - var shadowleft = $("") + var shadowleft = $("") .appendTo($("#sl")); - var shadowright = $("") + var shadowright = $("") .appendTo($("#sr")); $("#ubwidget") @@ -44,7 +45,6 @@ function init(){ titletext.click( function(){ - titletext.focus(); }); @@ -60,16 +60,16 @@ function init(){ controlTextField(); - if(window.uniboard){ - window.uniboard.setPreference("fontSize", newFontSize); + if(window.sankore){ + window.sankore.setPreference("fontSize", newFontSize); }; - textField.focus(); + if(!checkMinimize) + textField.focus(); }); fontUp.click( function(){ - var newFontSize = parseInt(currentFontSize) + 3; textField.css({ @@ -78,41 +78,40 @@ function init(){ controlTextField(); - if(window.uniboard){ - window.uniboard.setPreference("fontSize", newFontSize); + if(window.sankore){ + window.sankore.setPreference("fontSize", newFontSize); }; - textField.focus(); + if(!checkMinimize) + textField.focus(); }); minimize.click( function(){ - $('.ubw-container').animate({height:"26px"},100); - minimizedHeight = $('.ubw-container').height() ; + $('.ubw-container').animate({height:"26px"},500); + minimizedHeight = $('.ubw-container').height(); minimize.hide(); maximize.show(); + controlTextField(); $('#headtitle').show(); - window.resizeTo($('.ubw-container').width(),0); + $('#headtitle').focus(); + //window.resizeTo($('.ubw-container').width(),0); + checkMinimize = true; - if(window.uniboard){ - window.uniboard.setPreference("minimized", "true"); - }; }); maximize.click( function(){ var lastHeight = String(minimizedHeight)+'px'; - $('.ubw-container').animate({height: lastHeight},100); + $('.ubw-container').animate({height: lastHeight},500); maximize.hide(); minimize.show(); $('#headtitle').hide(); - - window.resizeTo($('.ubw-container').width()+15,minimizedHeight+20); + //textField.focus(); + //window.resizeTo($('.ubw-container').width()+15,minimizedHeight+20); + checkMinimize = false; - if(window.uniboard){ - window.uniboard.setPreference("minimized", "false"); - }; }); header @@ -126,11 +125,11 @@ function init(){ .css("fontSize",currentFontSize) .attr('contentEditable','true') .keyup(function(){ - if(window.uniboard){ - window.uniboard.setPreference("text", textField.html()); + if(window.sankore){ + window.sankore.setPreference("text", textField.html()); } controlTextField(); - $('#headtitle').hide(); + //$('#headtitle').hide(); }); if(textField.html().length === 0){ textField.focus(); @@ -139,10 +138,10 @@ function init(){ .attr('rows','1'); function controlTextField(){ - if(textField.text().length < 25){ - var titleStr = textField.text() + '...'; - $('#headtitle').val(titleStr); - } + if(textField.text().length < 25) + $('#headtitle').val(textField.text()); + else + $('#headtitle').val(textField.text().substr(0,25) + "..."); textField.css({ height : $('.ubw-container').height()-28, @@ -160,18 +159,19 @@ function init(){ textField.bind('paste', function(e) { controlTextField(); - }); + }); + $('#headtitle').hide(); - if(window.uniboard){ - text = window.uniboard.preference('text', text); - currentFontSize = window.uniboard.preference('fontSize', defaultFontSize); - + + if(window.sankore){ + text = window.sankore.preference('text', text); + currentFontSize = window.sankore.preference('fontSize', defaultFontSize); $('.ubw-container').css({ - width:parseInt(window.uniboard.preference('width', "300")), - height:parseInt(window.uniboard.preference('height', "240")) + width:window.innerWidth - 2, + height:window.innerHeight - 20 }); - if(window.uniboard.preference('minimized', "false") == "true"){ + if(checkMinimize){ minimize.trigger("click"); }; @@ -196,15 +196,14 @@ function init(){ if(winheight > 600) { window.resizeTo(winwidth,600); - } - - $('.ubw-container').width(winwidth-2) ; - $('.ubw-container').height(winheight-20) ; + } - if(window.uniboard){ - window.uniboard.setPreference("width", winwidth-2); - window.uniboard.setPreference("height", winheight-20); - } + $('.ubw-container').width(winwidth-2); + + if(checkMinimize) + minimizedHeight = winheight-40; + else + $('.ubw-container').height(winheight-40); controlTextField(); } diff --git a/resources/library/interactive/Stopwatch.wgt/js/ubw-main.js b/resources/library/interactive/Stopwatch.wgt/js/ubw-main.js index 6f7c1206..b6e2107e 100644 --- a/resources/library/interactive/Stopwatch.wgt/js/ubw-main.js +++ b/resources/library/interactive/Stopwatch.wgt/js/ubw-main.js @@ -1,91 +1,129 @@ function init(){ - var ubwidget = $("#ubwidget").ubwidget({ - width:252, - height:89 - }); + var ubwidget = $("#ubwidget").ubwidget({ + width:252, + height:89 + }); - var space = $("
h
").ubwbutton({w:17, h:68}); - space.find(".ubw-button-body").css({ - borderLeft:"none", - borderRight:"none" - }); - var spaceb = $("
m
").ubwbutton({w:17, h:68}); - spaceb.find(".ubw-button-body").css({ - borderLeft:"none", - borderRight:"none" - }); - spaceb.find(".ubw-button-canvas").unbind("mouseenter"); - var spacec = $("
s
").ubwbutton({w:17, h:68}); - spacec.find(".ubw-button-body").css({ - borderLeft:"none", - borderRight:"none" - }); - spacec.find(".ubw-button-canvas").unbind("mouseenter"); + var space = $("
h
").ubwbutton({ + w:17, + h:68 + }); + space.find(".ubw-button-body").css({ + borderLeft:"none", + borderRight:"none" + }); + var spaceb = $("
m
").ubwbutton({ + w:17, + h:68 + }); + spaceb.find(".ubw-button-body").css({ + borderLeft:"none", + borderRight:"none" + }); + spaceb.find(".ubw-button-canvas").unbind("mouseenter"); + var spacec = $("
s
").ubwbutton({ + w:17, + h:68 + }); + spacec.find(".ubw-button-body").css({ + borderLeft:"none", + borderRight:"none" + }); + spacec.find(".ubw-button-canvas").unbind("mouseenter"); - var hours = $("
00
").ubwbutton({w:52, h:68}, {bottom:1, top:1, right:0, left:0}); - hours.find(".ubw-button-body").css({ - borderRight:"none" - }); - var minutes = $("
00
").ubwbutton({w:52, h:68}, {bottom:1, top:1, right:0, left:0}); - minutes.find(".ubw-button-body").css({ - borderLeft:"none", - borderRight:"none" - }); - var seconds = $("
00
").ubwbutton({w:52, h:68}, {bottom:1, top:1, right:0, left:0}); - seconds.find(".ubw-button-body").css({ - borderLeft:"none", - borderRight:"none" - }); - var pause = $("
") - pause.css({ - marginLeft:8, - marginTop:3, - marginBottom:-2, - height:47 - }); + var hours = $("
00
").ubwbutton({ + w:52, + h:68 + }, { + bottom:1, + top:1, + right:0, + left:0 + }); + hours.find(".ubw-button-body").css({ + borderRight:"none" + }); + var minutes = $("
00
").ubwbutton({ + w:52, + h:68 + }, { + bottom:1, + top:1, + right:0, + left:0 + }); + minutes.find(".ubw-button-body").css({ + borderLeft:"none", + borderRight:"none" + }); + var seconds = $("
00
").ubwbutton({ + w:52, + h:68 + }, { + bottom:1, + top:1, + right:0, + left:0 + }); + seconds.find(".ubw-button-body").css({ + borderLeft:"none", + borderRight:"none" + }); + var pause = $("
") + pause.css({ + marginLeft:8, + marginTop:3, + marginBottom:-2, + height:47 + }); - var reset = $("
") - .css({ - marginLeft:8, - marginTop:1 - }) - .click(function(){ - $("#hours").find(".ubw-button-content").text("00"); - $("#minutes").find(".ubw-button-content").text("00"); - $("#seconds").find(".ubw-button-content").text("00"); - clearTimeout(currentTimer); - if(play){ - $("#pausebutton").trigger("click"); - } - }); + var reset = $("
") + .css({ + marginLeft:8, + marginTop:1 + }) + .click(function(){ + $("#hours").find(".ubw-button-content").text("00"); + $("#minutes").find(".ubw-button-content").text("00"); + $("#seconds").find(".ubw-button-content").text("00"); + clearTimeout(currentTimer); + if(play){ + $("#pausebutton").trigger("click"); + } + }); - if (window.widget) { - window.widget.onremove = function(){ - if(play){ - $("#pausebutton").trigger("click"); - }; - }; - }; + if (window.widget) { + window.widget.onremove = function(){ + if(play){ + $("#pausebutton").trigger("click"); + } + }; + } - pause.toggle( - function(){ - play = false; - clearTimeout(currentTimer); - $(this).find("img").attr("src", "images/button_play_invert.png"); - }, - function(){ - play = true; - var timeInSeconds = parseInt($("#seconds").find(".ubw-button-content").text(), 10) + - parseInt($("#minutes").find(".ubw-button-content").text(), 10)*60 + - parseInt($("#hours").find(".ubw-button-content").text(), 10)*3600; + pause.toggle( + function(){ + play = false; + clearTimeout(currentTimer); + $(this).find("img").attr("src", "images/button_play_invert.png"); + }, + function(){ + if($("#hours").find(".ubw-button-content").text() != "00" || + $("#minutes").find(".ubw-button-content").text() != "00" || + $("#seconds").find(".ubw-button-content").text() != "00") { + + play = true; + var timeInSeconds = parseInt($("#seconds").find(".ubw-button-content").text(), 10) + + parseInt($("#minutes").find(".ubw-button-content").text(), 10)*60 + + parseInt($("#hours").find(".ubw-button-content").text(), 10)*3600; - updateChronometerReverse(timeInSeconds); + updateChronometerReverse(timeInSeconds); - $(this).find("img").attr("src", "images/button_pause_invert.png"); - } - );/*.mouseenter(function(){ + $(this).find("img").attr("src", "images/button_pause_invert.png"); + } + } + );/*.mouseenter(function(){ var o = $(this).find("img").attr("src"); $(this).find("img").attr("src", o.split(".")[0]+"xov.png"); }).mouseout(function(){ @@ -93,103 +131,129 @@ function init(){ $(this).find("img").attr("src", o.split("x")[0]+".png"); });*/ - setTimeout(function(){pause.trigger("click")}, 200); + setTimeout(function(){ + pause.trigger("click") + }, 200); - hours - .bind("mousedown", {button:hours}, timeButtonDownHandler) - .find(".ubw-button-arrowTop").bind("mousedown",{button:hours}, addbtn); - hours - .find(".ubw-button-arrowBottom").bind("mousedown",{button:hours}, rembtn); - minutes - .bind("mousedown", {button:minutes}, timeButtonDownHandler) - .find(".ubw-button-arrowTop").bind("mousedown",{button:minutes}, addbtn); - minutes - .find(".ubw-button-arrowBottom").bind("mousedown",{button:minutes}, rembtn); - seconds - .bind("mousedown", {button:seconds}, timeButtonDownHandler) - .find(".ubw-button-arrowTop").bind("mousedown",{button:seconds}, addbtn); - seconds - .find(".ubw-button-arrowBottom").bind("mousedown",{button:seconds}, rembtn); + hours + .bind("mousedown", { + button:hours + }, timeButtonDownHandler) + .find(".ubw-button-arrowTop").bind("mousedown",{ + button:hours + }, addbtn); + hours + .find(".ubw-button-arrowBottom").bind("mousedown",{ + button:hours + }, rembtn); + minutes + .bind("mousedown", { + button:minutes + }, timeButtonDownHandler) + .find(".ubw-button-arrowTop").bind("mousedown",{ + button:minutes + }, addbtn); + minutes + .find(".ubw-button-arrowBottom").bind("mousedown",{ + button:minutes + }, rembtn); + seconds + .bind("mousedown", { + button:seconds + }, timeButtonDownHandler) + .find(".ubw-button-arrowTop").bind("mousedown",{ + button:seconds + }, addbtn); + seconds + .find(".ubw-button-arrowBottom").bind("mousedown",{ + button:seconds + }, rembtn); - $(document).mouseup(function(){ - /*if(isScrolling){ + $(document).mouseup(function(){ + /*if(isScrolling){ $().unbind("mousemove"); activeTimeScroll.find(".ubw-button-canvas") .bind("mouseleave", {button:activeTimeScroll}, buttonOutHandler) .bind("mouseenter", {button:activeTimeScroll}, buttonOverHandler); };*/ - clearTimeout(incDecTime); - }); + clearTimeout(incDecTime); + }); - var btnsWrapper = $("
") - .css({ - float:"left", - marginLeft:5, - marginTop:6 - }) - .append(pause) - .append(reset); + var btnsWrapper = $("
") + .css({ + float:"left", + marginLeft:5, + marginTop:6 + }) + .append(pause) + .append(reset); - ubwidget - .append(hours) - .append(space.clone()) - .append(minutes) - .append(spaceb) - .append(seconds) - .append(spacec) - .append(btnsWrapper); + ubwidget + .append(hours) + .append(space.clone()) + .append(minutes) + .append(spaceb) + .append(seconds) + .append(spacec) + .append(btnsWrapper); - clearTimeout(currentTimer); - updateChronometer(0); + clearTimeout(currentTimer); - var currentTimer = null; - var incDecTime = null; - var play = true; - var isScrolling = false; - var reverse = true; - var activeTimeScroll = null; + var currentTimer = null; + var incDecTime = null; + var play = true; + var isScrolling = false; + var reverse = true; + var activeTimeScroll = null; - function addbtn(m){ + function addbtn(m){ - var button = m.data.button; - var content = button.find(".ubw-button-content"); + var button = m.data.button; + var content = button.find(".ubw-button-content"); - if(content.text().substr(0, 1) == "0"){ - content.text(content.text().substr(1, content.text().length)) - } + if(content.text().substr(0, 1) == "0"){ + content.text(content.text().substr(1, content.text().length)) + } - content.text(formatTime(parseInt(content.text())+1)); + content.text(formatTime(parseInt(content.text())+1)); - incDecTime = setTimeout(function(){addbtn(m)},150); - }; + incDecTime = setTimeout(function(){ + addbtn(m) + },150); + } - function rembtn(m){ + function rembtn(m){ - var button = m.data.button; - var content = button.find(".ubw-button-content"); + var button = m.data.button; + var content = button.find(".ubw-button-content"); - if(content.text().substr(0, 1) == "0"){ - content.text(content.text().substr(1, content.text().length)) - } + if(content.text().substr(0, 1) == "0"){ + content.text(content.text().substr(1, content.text().length)) + } - content.text(formatTime(parseInt(content.text())-1)); + content.text(formatTime(parseInt(content.text())-1)); - incDecTime = setTimeout(function(){rembtn(m)},150); - }; + incDecTime = setTimeout(function(){ + rembtn(m); + },150); + } - function timeButtonDownHandler(m){ - var button = m.data.button; - var mouseStart = {pageX:m.pageX, pageY:m.pageY}; - var content = button.find(".ubw-button-content"); - var val = content.text(); - isScrolling = true; - reverse = true; - activeTimeScroll = button; - if(play){ - $("#pausebutton").trigger("click"); - } + function timeButtonDownHandler(m){ + var button = m.data.button; + var mouseStart = { + pageX:m.pageX, + pageY:m.pageY + }; + var content = button.find(".ubw-button-content"); + var val = content.text(); + isScrolling = true; + reverse = true; + activeTimeScroll = button; + if(play){ + $("#pausebutton").trigger("click"); + } - /*button.find(".ubw-button-canvas") + /*button.find(".ubw-button-canvas") .unbind("mouseenter") .unbind("mouseleave"); @@ -204,81 +268,89 @@ function init(){ content.text(content.text()%60); if(content.text() < 0)content.text(0); });*/ - }; + } - function buttonOverHandler(e) { - var button = e.data.button; - var buttonbody = button.find(".ubw-button-body"); + function buttonOverHandler(e) { + var button = e.data.button; + var buttonbody = button.find(".ubw-button-body"); - button.css({zIndex:1}) - buttonbody.removeClass("ubw-button-out") - .addClass("ubw-button-over") - .css({fontSize:"125%"}); + button.css({ + zIndex:1 + }) + buttonbody.removeClass("ubw-button-out") + .addClass("ubw-button-over") + .css({ + fontSize:"125%" + }); - button.find(".ubw-button-canvas").find(".ubw-button-arrowTop").children("img").attr("src", "images/arrows_over/top.png"); - button.find(".ubw-button-canvas").find(".ubw-button-arrowBottom").children("img").attr("src", "images/arrows_over/bottom.png"); - }; + button.find(".ubw-button-canvas").find(".ubw-button-arrowTop").children("img").attr("src", "images/arrows_over/top.png"); + button.find(".ubw-button-canvas").find(".ubw-button-arrowBottom").children("img").attr("src", "images/arrows_over/bottom.png"); + } - function buttonOutHandler(e){ - var button = e.data.button; - var buttonbody = button.find(".ubw-button-body"); + function buttonOutHandler(e){ + var button = e.data.button; + var buttonbody = button.find(".ubw-button-body"); - button.css({zIndex:0}); - buttonbody.removeClass("ubw-button-over") - .addClass("ubw-button-out") - .css({ - fontSize:"100%", - }); + button.css({ + zIndex:0 + }); + buttonbody.removeClass("ubw-button-over") + .addClass("ubw-button-out") + .css({ + fontSize:"100%" + }); - button.find(".ubw-button-canvas").find(".ubw-button-arrowTop").children("img").attr("src", "images/arrows_out/top.png"); - button.find(".ubw-button-canvas").find(".ubw-button-arrowBottom").children("img").attr("src", "images/arrows_out/top.png"); - }; + button.find(".ubw-button-canvas").find(".ubw-button-arrowTop").children("img").attr("src", "images/arrows_out/top.png"); + button.find(".ubw-button-canvas").find(".ubw-button-arrowBottom").children("img").attr("src", "images/arrows_out/top.png"); + } - function updateChronometerReverse(seconds){ + function updateChronometerReverse(seconds){ - currentTimer = setTimeout(function(){updateChronometerReverse(seconds-1)}, 1000); - if (seconds < 6 && seconds > 0){ - DHTMLSound('beep.wav'); - }else if(seconds === 0){ - DHTMLSound('finalbeep.wav'); - }; + currentTimer = setTimeout(function(){ + updateChronometerReverse(seconds-1) + }, 1000); + if (seconds < 6 && seconds > 0){ + DHTMLSound('beep.wav'); + }else if(seconds === 0){ + DHTMLSound('finalbeep.wav'); + } - if(seconds < 1){ - seconds = 0; - $("#pausebutton").trigger("click"); - } + if(seconds < 1){ + seconds = 0; + $("#pausebutton").trigger("click"); + } - var hoursValue = $("#hours").find(".ubw-button-content"); - var minutesValue = $("#minutes").find(".ubw-button-content"); - var secondsValue = $("#seconds").find(".ubw-button-content"); + var hoursValue = $("#hours").find(".ubw-button-content"); + var minutesValue = $("#minutes").find(".ubw-button-content"); + var secondsValue = $("#seconds").find(".ubw-button-content"); - var currentSecond = String(seconds%60); - var currentMinute = String(Math.floor(seconds/60)%60); - var currentHour = String(Math.floor(seconds/3600)); + var currentSecond = String(seconds%60); + var currentMinute = String(Math.floor(seconds/60)%60); + var currentHour = String(Math.floor(seconds/3600)); - hoursValue.text(formatTime(currentHour)); - minutesValue.text(formatTime(currentMinute)); - secondsValue.text(formatTime(currentSecond)); + hoursValue.text(formatTime(currentHour)); + minutesValue.text(formatTime(currentMinute)); + secondsValue.text(formatTime(currentSecond)); - } + } - function formatTime(time){ + function formatTime(time){ - document.title = time +", " + String(time).length; + document.title = time +", " + String(time).length; - if(time<0){ - time = 59; - } + if(time<0){ + time = 59; + } - time = time%60; + time = time%60; - String(time).length < 2 ? time = "0"+time : time = time; + String(time).length < 2 ? time = "0"+time : time = time; - return time; - } + return time; + } - function DHTMLSound(surl) { - document.getElementById("audio").innerHTML= - "