From: itozyun Date: Sun, 5 Aug 2012 08:19:32 +0000 (+0900) Subject: client is version 0.5.5, update around comic exproler. X-Git-Url: http://git.osdn.net/view?p=pettanr%2Fpettanr.git;a=commitdiff_plain;h=2c007c989e71c2742c0ff0d07d7ebcd48a88c106 client is version 0.5.5, update around comic exproler. --- diff --git a/app/assets/javascripts/peta.apps.js b/app/assets/javascripts/peta.apps.js index acf56469..304fbf66 100644 --- a/app/assets/javascripts/peta.apps.js +++ b/app/assets/javascripts/peta.apps.js @@ -1,6 +1,6 @@ /* - * pettanR system.js - * version 0.4.37 + * pettanR peta.apps.js + * version 0.5.5 * * author: * itozyun @@ -87,7 +87,7 @@ _rule, _Math_pow = Math.pow, _bits = 0; - if( typeof _license === 'object'){ + if( typeof _license === 'object' ){ for( i=0, l=BASIC_LICENSES.length; iCabinet
x
', + '
' + ].join( '' ); self.fetchCSS( '/assets/peta.apps.css' ); @@ -484,6 +488,10 @@ var Cabinet = gOS.registerApplication( function(){ delete self.onInit; }; this.onOpen = function( _w, _h ){ + headerH = Util.getElementSize( document.getElementById( 'cabinet-header' ) ).height; + + self.addMouseEventListener( document.getElementById( 'cabinet-close-button' ), 'click', Cabinet.shutdown ); + finder = self.createFinder( self.rootElement, tree ); self.onPaneResize( _w, _h ); }; @@ -493,21 +501,25 @@ var Cabinet = gOS.registerApplication( function(){ finder = tree = null; }; this.onPaneResize = function( _w, _h ){ - finder.resize( _w, _h ); + finder.resize( _w, _h - headerH ); }; }, false, true, 'Cabinet', 'cabinet', null, '#1C1C1C' ); var Gallery = gOS.registerApplication( function(){ var self = this, finder = null, - tree = null; + tree = null, + headerH = 0; this.bgColor = '#FFFFFF'; this.MIN_WIDTH = 500; this.MIN_HEIGHT = 300; this.onInit = function(){ self.rootElement.id = 'gallery-root'; - self.rootElement.innerHTML = ''; + self.rootElement.innerHTML = [ + '', + '' + ].join( '' ); self.fetchCSS( '/assets/peta.apps.css' ); @@ -521,6 +533,10 @@ var Gallery = gOS.registerApplication( function(){ _pic.destroy(); }; this.onOpen = function( _w, _h ){ + headerH = Util.getElementSize( document.getElementById( 'gallery-header' ) ).height; + + self.addMouseEventListener( document.getElementById( 'gallery-close-button' ), 'click', Gallery.shutdown ); + finder = self.createFinder( self.rootElement, tree ); self.onPaneResize( _w, _h ); }; @@ -530,7 +546,7 @@ var Gallery = gOS.registerApplication( function(){ finder = tree = null; }; this.onPaneResize = function( _w, _h ){ - finder.resize( _w, _h ); + finder.resize( _w, _h - headerH ); }; }, false, true, 'Gallery', 'gallery', null, '#01A31C' ); @@ -1018,7 +1034,6 @@ var Reader = gOS.registerApplication( function(){ } else { }; - if( comicData !== null ){ elmTitle.data = title; elmAuthor.data = author; @@ -1596,17 +1611,17 @@ var Editor = gOS.registerApplication( function(){ y = _y; w = _w; h = _h; - } + }; function bodyBackOrForward( isBack ){ - if( !self) return; - if( bodyIsTachable === !isBack) return; + if( !self ) return; + if( bodyIsTachable === !isBack ) return; elmBodyStyle.position = isBack === true ? 'relative' : 'absolute'; elmBodyStyle.left = isBack === true ? 0 : x +'px'; - elmBodyStyle.top = isBack === true ? 0 : y +headerH +'px'; - elmBodyStyle.width = isBack === true ? '' : ( w -WINDOW_BODY_BODER_SIZE *2) +'px'; + elmBodyStyle.top = isBack === true ? 0 : y + headerH + 'px'; + elmBodyStyle.width = isBack === true ? '' : ( w - WINDOW_BODY_BODER_SIZE * 2 ) + 'px'; bodyIsTachable === isBack && isBack === true ? elmHeader.parentNode.insertBefore( elmBody, elmHeader.nextSibling ) : app.rootElement.appendChild( elmBody ); bodyIsTachable = !isBack; - } + }; this.init = function(){ self.elm = elmWindowOrigin.cloneNode( true ); @@ -1683,7 +1698,7 @@ var Editor = gOS.registerApplication( function(){ }; this.onFadeOut = function(){ self.elm.parentNode.removeChild( self.elm ); - self.onClose && setTimeout( self.onClose, 0 ); + self.onClose && app.addAsyncCall( self.onClose ); }; this.close = function(){ if( visible === false) return; @@ -1876,21 +1891,21 @@ var Editor = gOS.registerApplication( function(){ function addImage(){ IMAGE_EXPLORER_WINDOW.open();// setTimeout( IMAGE_EXPLORER_WINDOW.open, 0); TOOL_BOX_WINDOW.bodyBackOrForward( true ); - } + }; function addText(){ - setTimeout( PANEL_ELEMENT_CONTROL.createTextElement, 0 ); - } + app.addAsyncCall( PANEL_ELEMENT_CONTROL.createTextElement ); + }; function switchGrid(){ - setTimeout( GRID_CONTROL.update, 0 ); - } + app.addAsyncCall( GRID_CONTROL.update ); + }; function popupHelp(){ TOOL_BOX_WINDOW.bodyBackOrForward( true ); - setTimeout( HELP_DOCUMENTS_WINDOW.open, 0 ); - } + app.addAsyncCall( HELP_DOCUMENTS_WINDOW.open ); + }; function editBG( e ){ TOOL_BOX_WINDOW.bodyBackOrForward( true ); - setTimeout( INFOMATION_WINDOW.open, 0 ); - } + app.addAsyncCall( INFOMATION_WINDOW.open ); + }; return WINDOWS_CONTROL.createWindow( { @@ -2149,17 +2164,17 @@ var Editor = gOS.registerApplication( function(){ jqAjaxContents.removeClass( 'loading' ).append( elmNavi, elmPages ); jqNaviItems = jqAjaxContents.find( 'a.' + elmItemOrigin.className ).click( onNaviClick ); - jqPages = jqAjaxContents.find( '.page-content' ); + jqPages = jqAjaxContents.find( '.page-content' ); jqPages.find( 'a' ).click( onInnerLinkClick ); - setTimeout( jumpPage, 0 ); + app.addAsyncCall( jumpPage ); } function onSelectionClick( _pageIndex ){ HELP_DOCUMENTS_WINDOW.open(); jumpPage( _pageIndex ); } function jumpPage( _index ){ - if( typeof _index === 'number' && 0 <= _index && _index < numPage && currentPageIndex !== _index ){ + if( Type.isNumber( _index ) === true && 0 <= _index && _index < numPage && currentPageIndex !== _index ){ currentPageIndex = _index; } jqNaviItems.removeClass( 'current' ).eq( currentPageIndex).addClass( 'current' ); @@ -2182,7 +2197,7 @@ var Editor = gOS.registerApplication( function(){ onInit: function(){ help = MENU_BAR_CONTROL.HELP; onLoadFunction = help.createAjaxSelection( onAjaxStart ); - jqAjaxContents = $( HELP_DOCUMENTS_WINDOW.elm ).find( '.window-body' ).addClass( 'loading' ); + jqAjaxContents = $( HELP_DOCUMENTS_WINDOW.elm ).find( '.window-body' ).addClass( 'loading' ).css( { overflow: 'auto' } ); delete HELP_DOCUMENTS_WINDOW.onInit; }, onFirstOpen: function( _w, _h ){ @@ -4099,7 +4114,7 @@ var ComicConsole = gOS.registerApplication( function(){ var elmHeader, elmProgress, winW, winH, inputTitle, inputW, inputH, - comboboxVisible, comboboxEditable, + comboboxVisible, // comboboxEditable, buttonSubmit, buttonCancel, elmUploader = null, elmScript = null, @@ -4143,7 +4158,7 @@ var ComicConsole = gOS.registerApplication( function(){ _select.selectedIndex = comboboxVisible.selectIndex(); } else if( _name === 'comic[editable]'){ - _select.selectedIndex = comboboxEditable.selectIndex(); + // _select.selectedIndex = comboboxEditable.selectIndex(); }; }; try { @@ -4173,6 +4188,12 @@ var ComicConsole = gOS.registerApplication( function(){ }; function onIframeUpdate(){ elmIframe.onload = null; + try { + console.log( ( elmIframe.contentWindow || elmIframe.contentDocument.parentWindow ).document.body.innerHTML ); + } catch(e){ + + } + ( elmIframe.contentWindow || elmIframe.contentDocument.parentWindow ).close(); elmIframe = null; elmProgress.innerHTML = 'success!'; @@ -4200,7 +4221,7 @@ var ComicConsole = gOS.registerApplication( function(){ comboboxVisible.createOption( option.innerHTML, option.value, option.selected ); } else if( select.name === 'comic[editable]' ){ - comboboxEditable.createOption( option.innerHTML, option.value, option.selected ); + // comboboxEditable.createOption( option.innerHTML, option.value, option.selected ); }; }; }; @@ -4245,10 +4266,10 @@ var ComicConsole = gOS.registerApplication( function(){ 'Visible:', '', '', - '
', - 'Editable:', - '', - '
', + //'
', + // 'Editable:', + // '', + //'
', '
', '
create
', '
cancel
', @@ -4268,7 +4289,7 @@ var ComicConsole = gOS.registerApplication( function(){ inputW = ui.createInputText( document.getElementById( 'comic-console-width') ); inputH = ui.createInputText( document.getElementById( 'comic-console-height') ); comboboxVisible = ui.createCombobox( document.getElementById( 'comic-console-visible') ); - comboboxEditable = ui.createCombobox( document.getElementById( 'comic-console-editable') ); + // comboboxEditable = ui.createCombobox( document.getElementById( 'comic-console-editable') ); buttonSubmit = ui.createButton( document.getElementById( 'comic-console-post-button'), clickOK ); buttonCancel = ui.createButton( document.getElementById( 'comic-console-cancel-button'), clickCancel ); @@ -4503,6 +4524,11 @@ var PanelConsole = gOS.registerApplication( function(){ }; }; function onLoad(){ + try { + console.log( ( elmIframe.contentWindow || elmIframe.contentDocument.parentWindow ).document.body.innerHTML ); + } catch(e){ + + } elmIframe.onload = null; ( elmIframe.contentWindow || elmIframe.contentDocument.parentWindow ).close(); elmProgress.innerHTML = 'success!'; @@ -5024,10 +5050,10 @@ var OutputConsole = gOS.registerApplication( function(){ elmOutputArea = document.getElementById( 'output-area' ); var ui = instance.createUIGroup(); - comboboxFormat = ui.createCombobox( document.getElementById( 'output-console-format' ) ); + comboboxFormat = ui.createCombobox( document.getElementById( 'output-console-format' ), clickGenerate ); for( var i=0; FORMAT_LIST[ 0 ]; ++i ){ - comboboxFormat.createOption( FORMAT_LIST.pop(), null, i === 0 ); + comboboxFormat.createOption( FORMAT_LIST.shift(), null, i === 0 ); }; inputOption = ui.createInputText( document.getElementById( 'output-console-option' ), null ); buttonGenerate = ui.createButton( document.getElementById( 'output-console-generate-button' ), clickGenerate ); diff --git a/app/assets/javascripts/peta.common.js b/app/assets/javascripts/peta.common.js index 9bc5f046..dc9217b2 100644 --- a/app/assets/javascripts/peta.common.js +++ b/app/assets/javascripts/peta.common.js @@ -1,8 +1,11 @@ /* - * pettanR common.js - * version 0.4.37 + * pettanR peta.common.js + * version 0.5.4 * - * author: itozyun + * author: + * itozyun + * licence: + * 3-clause BSD */ var pettanr = ( function(){ @@ -37,7 +40,7 @@ var pettanr = ( function(){ })(), IS_DEBUG = Type.isBoolean( URL_PARAMS.debug ) ? URL_PARAMS.debug : IS_LOCAL === true; return { - version: '0.5.0', + version: '0.5.5', URL_PARAMS: URL_PARAMS, LOCAL: IS_LOCAL, DEBUG: IS_DEBUG, @@ -686,6 +689,8 @@ pettanr.bind = ( function(){ _comicElements = json.panel_elements || [], _comicElement, _elmImg, _rImg, _rPic, _balloon, _elmBalloonWrap, _elmText, _text, _speechesAttributes, _key; + elmTarget.appendChild( _elmPanel ); + if( noClassnameMode === true ){ } else { @@ -694,8 +699,7 @@ pettanr.bind = ( function(){ for( var _key in _style ){ _cssText.push( _key + ':' + _style[ _key ] ); } - _elmPanel.style.cssText = _cssText.join( ';'); - elmTarget.appendChild( _elmPanel ); + _elmPanel.style.cssText = _cssText.join( ';' ); for( var i=0, l=_comicElements.length; i _w || self.MIN_HEIGHT > _h ){ - if( Type.isHTMLElement( self.rootElement ) === true ){ - // 小さすぎる!、と表示 - } - } - if( arguments.length > 2 ){ - self.onOpen.apply( self, arguments ); + bootParams = Util.copyArray( arguments ); + + if( this.rootElement.innerHTML && this.rootElement.innerHTML.length > 0 ){ + SystemTimer.add( self, detect, 16 ); } else { - self.onOpen( _w, _h ); + onOpen(); } - phase = 4; + + function detect(){ + if( self.rootElement.firstChild && fetchResource === 0 ){ + SystemTimer.remove( self, detect ); + onOpen(); + }; + }; + + function onOpen(){ + if( self.MIN_WIDTH > _w || self.MIN_HEIGHT > _h ){ + if( Type.isHTMLElement( self.rootElement ) === true ){ + // 小さすぎる!、と表示 + } + } + if( bootParams.length > 2 ){ + self.onOpen.apply( self, bootParams ); + } else { + self.onOpen( _w, _h ); + } + phase = 4; + }; }; this.resize = function( _w, _h ){ + if( phase !== 4 ) return; if( self.MIN_WIDTH > _w || self.MIN_HEIGHT > _h ){ if( Type.isHTMLElement( self.rootElement ) === true ){ // 小さすぎる!、と表示 @@ -1721,12 +1759,13 @@ var AbstractApplication = function( displayName, appClass, isOverlay ){ }; this.fetchCSS = function( _url, opt_onload, opt_onerror ){ if( phase === 1 ){ - Css.load( self, _url, fetchResourceComplete ); + ++fetchResource; + Css.load( self, _url, fetchResourceComplete, fetchResourceComplete ); }; }; function fetchResourceComplete(){ - alert( phase ); + --fetchResource; }; }; @@ -2124,7 +2163,7 @@ var Application = ( function(){ delete this.handler; delete this.destroy; }; - } + }; } else { wrappedEventClass = function( e, element ){ this._event = e; @@ -2147,13 +2186,13 @@ var Application = ( function(){ this.wheelDelta = e.wheelDelta; e = element = null; - } + }; wrappedEventClass.prototype.stopPropagation = function(){ this._event.cancelBubble = true; - } + }; wrappedEventClass.prototype.preventDefault = function(){ this._event.returnValue = false; - } + }; if( doc.attachEvent ){ wrappedHandlerClass = function( element, handler ){ @@ -2191,6 +2230,9 @@ var Application = ( function(){ this.element[ 'on' + this.eventType ] = function( e ){ return self.fire( self, e ); }; + this.clean = function(){ + self = null; + }; _ticket = null; }; tmp.ticketClass.prototype = { @@ -2222,11 +2264,13 @@ var Application = ( function(){ return true; }, destroy: function(){ + this.clean(); this.element[ 'on' + this.eventType ] = ''; tmp.list.splice( Util.getIndex( tmp.list, this ), 1 ); delete this.element; delete this.eventType; delete this.handlers; + delete this.clean; } }; }; @@ -2860,18 +2904,26 @@ var KeyEvent = ( function(){ } })(); +/** + * + * http://thudjs.tumblr.com/post/637855087/stylesheet-onload-or-lack-thereof + */ + var Css = ( function(){ var head = doc.getElementsByTagName( 'head' )[ 0 ]; var TICKET_LIST = []; var STATE_LIST = 'loaded,complete,uninitialized'.split( ',' ); + var cssRules, sheet; + var FetchCssTicketClass = function( _apiuser, _url, _elm, _onload, _onerror ){ this.apiusers = [ _apiuser ]; this.url = _url; this.elm = _elm; this.onload = [ _onload ]; this.onerror = [ _onerror ]; + this.time = 0; }; FetchCssTicketClass.prototype = { match: function( _apiuser, _url ){ @@ -2899,9 +2951,32 @@ var Css = ( function(){ delete this.elm; delete this.onload; delete this.onerror; + delete this.time; return true; }, + loaded: function(){ + for( var i = this.onload.length, f; i; ){ + f = this.onload[ --i ]; + Type.isFunction( f ) === true && AsyncCall.add( this.apiusers[ i ], f, this.url ); + this.onload[ i ] = this.onerror[ i ] = null; + }; + }, + error: function(){ + for( var i = this.onerror.length, c; i; ){ + c = this.onerror[ --i ]; + Type.isFunction( c ) === true && AsyncCall.add( t.apiusers[ i ], c, t.url ); + this.onload[ i ] = this.onerror[ i ] = null; + }; + }, + check: function(){ + var el = this.elm; + try { + return el[ sheet ] && el[ sheet ][ cssRules ].length > 0; + } catch( e ){ + return false; + }; + }, done: false }; @@ -2914,17 +2989,33 @@ var Css = ( function(){ function detect(){ var t = getTicket( this ), rs = this.readyState, c; - if( t && t.done === false && ( !rs || Util.getIndex( STATE_LIST, rs ) !== -1 ) ){ + if( t && t.done === false && ( !rs || Util.getIndex( STATE_LIST, rs ) !== -1 ) ){ t.done = true; - for( var i = t.onload.length; i; ){ - c = t.onload[ --i ]; - Type.isFunction( c ) === true && AsyncCall.add( t.apiusers[ i ], c, t.url ); - }; + t.loaded(); this.onreadystatechange = new Function(); this.onload = null; }; }; + function checkTimer(){ + var l = TICKET_LIST.length, + n = 0; + for( var i = 0; i < l; ++i ){ + t = TICKET_LIST[ i ]; + ++t.time; + if( t.check() === true ){ + t.loaded(); + ++n; + } else + if( t.time > 99 ){ + t.error(); + } else { + + }; + }; + l === n && SystemTimer.remove( SUPER_USER_KEY, checkTimer ); + }; + return { load: function( _apiuser, _url, opt_onload, opt_onerror ){ _url = Util.getAbsolutePath( _url ); @@ -2937,6 +3028,7 @@ var Css = ( function(){ t.onload.push( opt_onload ); t.onerror.push( opt_onerror ); }; + SystemTimer.add( SUPER_USER_KEY, checkTimer, 333 ); return; }; }; @@ -2947,7 +3039,18 @@ var Css = ( function(){ elm.onreadystatechange = elm.onload = detect; elm.href = _url; + if( !sheet ){ // only assign these once + cssRules = 'cssRules'; + sheet = 'sheet'; + if ( !( sheet in elm ) ) { // MSIE uses non-standard property names + cssRules = 'rules'; + sheet = 'styleSheet'; + }; + }; + TICKET_LIST.push( new FetchCssTicketClass( _apiuser, _url, elm, opt_onload, opt_onerror ) ); + + SystemTimer.add( SUPER_USER_KEY, checkTimer, 333 ); }, unload: function( _apiuser, _url ){ _url = _url ? Util.getAbsolutePath( _url ) : null; @@ -2959,6 +3062,9 @@ var Css = ( function(){ ++i; } }; + if( TICKET_LIST.length === 0 ){ + SystemTimer.remove( SUPER_USER_KEY, checkTimer ); + } } } })(); @@ -3317,7 +3423,8 @@ var UI = ( function(){ elmValue.data = _option.displayValue; if( focus === true ){ OptionControl.update( instance, _value ); - } + }; + Type.isFunction( onUpdate ) === true && onUpdate( _value ); break; } } @@ -3466,9 +3573,9 @@ var UI = ( function(){ currentCombobox = _combobox; elm = _combobox.elm; - for( var i = _optionList.length; i; ){ - OPTION_LIST.unshift( new OptionClass( _apiuser, _optionList[ --i ] ) ); - } + for( var i = 0, l = _optionList.length; i 0 ){ BREAD_ARRAY.shift().destroy(); - } + }; while( ICON_ARRAY.length > 0 ){ ICON_ARRAY.shift().destroy(); - } + }; + + FINDER_ARRAY.splice( Util.getIndex( FINDER_ARRAY, instance ), 1 ); }; }; FinderClass.prototype = new AbstractBasicPane(); - function getFinderIcon( _file, _elmContainer, w, index, style, onDown, onEditor, onViwer, onAction){ + function getFinderIcon( _file, _elmContainer, w, index, style, onDown, onEditor, onViwer, onAction ){ var _icon; if( FINDER_ICON_POOL.length > 0){ _icon = FINDER_ICON_POOL.shift(); } else { _icon = new FinderIconClass(); - } + }; _icon.init( _file, _elmContainer, w, index, style, onDown, onEditor, onViwer, onAction ); return _icon; - } + }; function getBreadcrumb( _file, _elmContainer, index, callback ){ var _bread; @@ -4055,10 +4164,10 @@ var Finder = ( function(){ _bread = BREAD_OBJECT_POOL.shift(); } else { _bread = new BreadcrumbClass(); - } + }; _bread.init( _file, _elmContainer, index, callback ); return _bread; - } + }; return { init: function(){ @@ -4086,7 +4195,7 @@ var Finder = ( function(){ }, isFinderHeadInstance: function(){ } - } + }; })(); diff --git a/app/assets/stylesheets/admins/sessions.css.scss b/app/assets/stylesheets/admins/sessions.css.scss deleted file mode 100644 index c6bbc18d..00000000 --- a/app/assets/stylesheets/admins/sessions.css.scss +++ /dev/null @@ -1,3 +0,0 @@ -// Place all the styles related to the admins/sessions controller here. -// They will automatically be included in application.css. -// You can use Sass (SCSS) here: http://sass-lang.com/ diff --git a/app/assets/stylesheets/artists.css.scss b/app/assets/stylesheets/artists.css.scss deleted file mode 100644 index cf638780..00000000 --- a/app/assets/stylesheets/artists.css.scss +++ /dev/null @@ -1,3 +0,0 @@ -// Place all the styles related to the artists controller here. -// They will automatically be included in application.css. -// You can use Sass (SCSS) here: http://sass-lang.com/ diff --git a/app/assets/stylesheets/author_registrations.css.scss b/app/assets/stylesheets/author_registrations.css.scss deleted file mode 100644 index a97efb96..00000000 --- a/app/assets/stylesheets/author_registrations.css.scss +++ /dev/null @@ -1,3 +0,0 @@ -// Place all the styles related to the author_registrations controller here. -// They will automatically be included in application.css. -// You can use Sass (SCSS) here: http://sass-lang.com/ diff --git a/app/assets/stylesheets/authors.css.scss b/app/assets/stylesheets/authors.css.scss deleted file mode 100644 index fb565e95..00000000 --- a/app/assets/stylesheets/authors.css.scss +++ /dev/null @@ -1,3 +0,0 @@ -// Place all the styles related to the authors controller here. -// They will automatically be included in application.css. -// You can use Sass (SCSS) here: http://sass-lang.com/ diff --git a/app/assets/stylesheets/authors/sessions.css.scss b/app/assets/stylesheets/authors/sessions.css.scss deleted file mode 100644 index 244137d9..00000000 --- a/app/assets/stylesheets/authors/sessions.css.scss +++ /dev/null @@ -1,3 +0,0 @@ -// Place all the styles related to the authors/sessions controller here. -// They will automatically be included in application.css. -// You can use Sass (SCSS) here: http://sass-lang.com/ diff --git a/app/assets/stylesheets/baloon_templates.css.scss b/app/assets/stylesheets/baloon_templates.css.scss deleted file mode 100644 index 06e9b148..00000000 --- a/app/assets/stylesheets/baloon_templates.css.scss +++ /dev/null @@ -1,3 +0,0 @@ -// Place all the styles related to the baloon_templates controller here. -// They will automatically be included in application.css. -// You can use Sass (SCSS) here: http://sass-lang.com/ diff --git a/app/assets/stylesheets/baloon_types.css.scss b/app/assets/stylesheets/baloon_types.css.scss deleted file mode 100644 index ca4b2f33..00000000 --- a/app/assets/stylesheets/baloon_types.css.scss +++ /dev/null @@ -1,3 +0,0 @@ -// Place all the styles related to the baloon_types controller here. -// They will automatically be included in application.css. -// You can use Sass (SCSS) here: http://sass-lang.com/ diff --git a/app/assets/stylesheets/baloons.css.scss b/app/assets/stylesheets/baloons.css.scss deleted file mode 100644 index 67e17d0a..00000000 --- a/app/assets/stylesheets/baloons.css.scss +++ /dev/null @@ -1,3 +0,0 @@ -// Place all the styles related to the baloons controller here. -// They will automatically be included in application.css. -// You can use Sass (SCSS) here: http://sass-lang.com/ diff --git a/app/assets/stylesheets/comics.css.scss b/app/assets/stylesheets/comics.css.scss deleted file mode 100644 index 6ef66b03..00000000 --- a/app/assets/stylesheets/comics.css.scss +++ /dev/null @@ -1,3 +0,0 @@ -// Place all the styles related to the comics controller here. -// They will automatically be included in application.css. -// You can use Sass (SCSS) here: http://sass-lang.com/ diff --git a/app/assets/stylesheets/common_licenses.css.scss b/app/assets/stylesheets/common_licenses.css.scss deleted file mode 100644 index 3d954b1c..00000000 --- a/app/assets/stylesheets/common_licenses.css.scss +++ /dev/null @@ -1,3 +0,0 @@ -// Place all the styles related to the common_lisences controller here. -// They will automatically be included in application.css. -// You can use Sass (SCSS) here: http://sass-lang.com/ diff --git a/app/assets/stylesheets/help.css.scss b/app/assets/stylesheets/help.css.scss deleted file mode 100644 index a2342cbc..00000000 --- a/app/assets/stylesheets/help.css.scss +++ /dev/null @@ -1,3 +0,0 @@ -// Place all the styles related to the help controller here. -// They will automatically be included in application.css. -// You can use Sass (SCSS) here: http://sass-lang.com/ diff --git a/app/assets/stylesheets/home.css.scss b/app/assets/stylesheets/home.css.scss deleted file mode 100644 index f0ddc684..00000000 --- a/app/assets/stylesheets/home.css.scss +++ /dev/null @@ -1,3 +0,0 @@ -// Place all the styles related to the home controller here. -// They will automatically be included in application.css. -// You can use Sass (SCSS) here: http://sass-lang.com/ diff --git a/app/assets/stylesheets/licenses.css.scss b/app/assets/stylesheets/licenses.css.scss deleted file mode 100644 index ea7f80b0..00000000 --- a/app/assets/stylesheets/licenses.css.scss +++ /dev/null @@ -1,3 +0,0 @@ -// Place all the styles related to the lisences controller here. -// They will automatically be included in application.css. -// You can use Sass (SCSS) here: http://sass-lang.com/ diff --git a/app/assets/stylesheets/original_licenses.css.scss b/app/assets/stylesheets/original_licenses.css.scss deleted file mode 100644 index f9474df2..00000000 --- a/app/assets/stylesheets/original_licenses.css.scss +++ /dev/null @@ -1,3 +0,0 @@ -// Place all the styles related to the original_lisences controller here. -// They will automatically be included in application.css. -// You can use Sass (SCSS) here: http://sass-lang.com/ diff --git a/app/assets/stylesheets/original_pictures.css.scss b/app/assets/stylesheets/original_pictures.css.scss deleted file mode 100644 index 48be6db2..00000000 --- a/app/assets/stylesheets/original_pictures.css.scss +++ /dev/null @@ -1,3 +0,0 @@ -// Place all the styles related to the original_pictures controller here. -// They will automatically be included in application.css. -// You can use Sass (SCSS) here: http://sass-lang.com/ diff --git a/app/assets/stylesheets/panels.css.scss b/app/assets/stylesheets/panels.css.scss deleted file mode 100644 index 9d1f3f66..00000000 --- a/app/assets/stylesheets/panels.css.scss +++ /dev/null @@ -1,3 +0,0 @@ -// Place all the styles related to the panels controller here. -// They will automatically be included in application.css. -// You can use Sass (SCSS) here: http://sass-lang.com/ diff --git a/app/assets/stylesheets/peta.apps.css b/app/assets/stylesheets/peta.apps.css index fc4de97a..31c9fbca 100644 --- a/app/assets/stylesheets/peta.apps.css +++ b/app/assets/stylesheets/peta.apps.css @@ -1,13 +1,12 @@ @charset "UTF-8"; -/* - * pettanR +/* pettanR peta.apps.css + * version 0.5.5 * - * work.css - * - * version 0.4.35 - * + * author: + * itozyun */ + html, body { overflow: hidden; } @@ -18,12 +17,38 @@ .console-page { } + + #editor { font-size: 9pt; } /*-------------------------------------------------------------------------------------- * + * Cabinet, Gallery + * + -------------------------------------------------------------------------------------*/ + #cabinet-header, #gallery-header { + position: relative; + background-color: #111; + color: #fff; + font-size: 12pt; + line-height: 1; + padding: 6pt 0 6pt 5pt; + } + #cabinet-close-button, #gallery-close-button { + position: absolute; + right: 0; + top: 0; + border-left: 1px solid #666; + height: 24pt; + padding: 6pt 9pt 6pt 9pt; + text-align: center; + cursor: pointer; + } + +/*-------------------------------------------------------------------------------------- + * * overlay * -------------------------------------------------------------------------------------*/ @@ -244,14 +269,6 @@ #upload-console { } -/*-------------------------------------------------------------------------------------- - * - * home - * - -------------------------------------------------------------------------------------*/ - #home { - - } /*-------------------------------------------------------------------------------------- @@ -1108,237 +1125,7 @@ background-repeat: repeat; /* background-image: url('grid.gif'); grid用イメージはgrid使用時にjsで埋め込み */ } - -/*-------------------------------------------------------------------------------------- - * - * Finder - * - -------------------------------------------------------------------------------------*/ - .finder-body { - position: relative; - overflow: auto; - } - .finder-container .loading { - background-position: 50% bottom; - } - .finder-header { - height: 40px; - position: relative; - background-color: #333; - } - .finder-header ul { - list-style: none; - position: absolute; - top: 0; - left: 48px; - height: 40px; - line-height: 40px; - padding: 0; - margin: 0; - } - .finder-header li { - position: absolute; - top: 0; - left: 0; - height: 40px; - width: 90px; - padding: 0; - margin: 0; - } - .finder-header li a, - .finder-header li a:link, - .finder-header li a:visited { - display: block; - height: 14px; - font-size: 14px; - line-height: 14px; - padding: 16px 0 10px 20px; - margin: 0; - color: #eee; - overflow: hidden; - } - .finder-header li a:hover { - text-decoration: none; - background-color: #66f; - color: #eee; - } - - - .finder-header .button { - position: absolute; - top: 8px; - width: 30px; - height: 24px; - line-height: 24px; - } - .finder-sidebar-switch { - left: 8px; - } - .finder-style-switch { - right: 48px; - } - .finder-action-switch { - right: 8px; - } - /* Finder Icon - --------------------------------------------------------------------------------------*/ - .finder-icon { - position: relative; - height: 74px; - border-bottom: 1px solid #ccc; - clear: both; - overflow: hidden; /* for webkit */ - } - .finder-icon:hover { - background-color: #eee; - cursor: pointer; - } - .fnder-icon-modern .finder-icon-handle, - .fnder-icon-modern .finder-icon-thumbnail, - .fnder-icon-modern .finder-icon-filename, - .fnder-icon-modern .finder-icon-summary { - display: table-cell; - vertical-align: middle; - line-height: 1.3em; - } - - .finder-icon-handle { - width: 20px; - height: 74px; - } - - .finder-icon-thumbnail { - width: 64px; - height: 74px; - cursor: pointer; - background-repeat: no-repeat; - background-position: 50% 50%; - background-image: url('/assets/sprite.gif'); - } - .finder-icon .file-type-folder { - background-position: 0 -75px; - } - .finder-icon .file-type-album { - } - .finder-icon .file-type-author { - background-position: -70px -75px; - } - .finder-icon .file-type-comic { - background-position: 0 -145px; - } - .finder-icon .file-type-cabinet { - background-position: -70px -145px; - } - .finder-icon .file-type-panel { - background-position: 0 -215px; - } - .finder-icon .file-type-artist { - background-position: -70px -215px; - } - .finder-icon .file-type-balloon { - background-position: 0 -285px; - } - .finder-icon .file-type-charactor { - background-position: -70px -285px; - } - .has-thumbnail { - } - .fnder-icon-modern .finder-icon-filename { - width: 200px; - padding: 5px 10px; - height: 64px; - font-weight: bold; - color: #333; - } - .fnder-icon-modern .finder-icon-summary { - width: 300px; - padding: 5px 10px; - height: 64px; - color: #666; - } - - /* Finder Icon ie7- - --------------------------------------------------------------------------------------*/ - .finder-icon a, - .finder-icon a:link, - .finder-icon a:visited, - .finder-icon a:active { - display: block; - height: 74px; - text-decoration: none; - zoom: 1; - cursor: pointer; - } - .finder-icon a:hover { - _background-color: #eee; - color: #333; - } - .fnder-icon-ie7 .finder-icon-handle, - .fnder-icon-ie7 .finder-icon-thumbnail { - zoom: 1; - line-height: 1.3em; - } - .finder-icon-cell { - display: inline; - zoom: 1; - } - .finder-icon-vertical-middle-outer { - display: block; - height: 74px; - position: relative; - } - .finder-icon-ie-filename .finder-icon-vertical-middle-outer { - width: 200px; - font-weight: bold; - color: #333; - } - .finder-icon-ie-summary .finder-icon-vertical-middle-outer { - width: 300px; - color: #666; - } - .finder-icon-vertical-middle-inner { - display: block; - position: absolute; - top: 50%; - margin: 0 5px; - } - .fnder-icon-ie7 .finder-icon-filename, - .fnder-icon-ie7 .finder-icon-summary { - position: relative; - top: -50%; - } - - /* Finder Icon Console - --------------------------------------------------------------------------------------*/ - .finder-icon-console { - position: absolute; - top: 0; - right: 0; - } - .finder-icon-console a { - display: block; - width: 74px; - height: 74px; - border-left: 1px solid #ccc; - float: right; - background-image: url('/assets/sprite.gif') !important; - background-repeat: no-repeat; - } - .finder-icon-console a:hover { - background-color: #ccc !important; - } - .finder-icon-console-action { - background-position: 0px -355px; - } - .finder-icon-console-editor-apps { - background-position: -70px -355px; - } - .finder-icon-console-viewer-apps { - background-position: 0px -425px; - } - - - + \ No newline at end of file diff --git a/app/assets/stylesheets/peta.common.css b/app/assets/stylesheets/peta.common.css index 3265738d..ac5c3372 100644 --- a/app/assets/stylesheets/peta.common.css +++ b/app/assets/stylesheets/peta.common.css @@ -1,14 +1,19 @@ @charset "UTF-8"; -/* - * pettanR +/* pettanR peta.ccommon.css + * version 0.5.4 * - * common.css - * - * version 0.4.23 - * + * author: + * itozyun */ +/* VML ( v\:* don't work for ie8(ie8mode)) +--------------------------------------------------------------------------------------*/ + v\:shape, + v\:image { + behavior: url(#default#VML); + display: block; + } /* dl table --------------------------------------------------------------------------------------*/ diff --git a/app/assets/stylesheets/pictures.css.scss b/app/assets/stylesheets/pictures.css.scss deleted file mode 100644 index 83553278..00000000 --- a/app/assets/stylesheets/pictures.css.scss +++ /dev/null @@ -1,3 +0,0 @@ -// Place all the styles related to the pictures controller here. -// They will automatically be included in application.css. -// You can use Sass (SCSS) here: http://sass-lang.com/ diff --git a/app/assets/stylesheets/scaffolds.css.scss b/app/assets/stylesheets/scaffolds.css.scss deleted file mode 100644 index 05188f08..00000000 --- a/app/assets/stylesheets/scaffolds.css.scss +++ /dev/null @@ -1,56 +0,0 @@ -body { - background-color: #fff; - color: #333; - font-family: verdana, arial, helvetica, sans-serif; - font-size: 13px; - line-height: 18px; } - -p, ol, ul, td { - font-family: verdana, arial, helvetica, sans-serif; - font-size: 13px; - line-height: 18px; } - -pre { - background-color: #eee; - padding: 10px; - font-size: 11px; } - -a { - color: #000; - &:visited { - color: #666; } - &:hover { - color: #fff; - background-color: #000; } } - -div { - &.field, &.actions { - margin-bottom: 10px; } } - -#notice { - color: green; } - -.field_with_errors { - padding: 2px; - background-color: red; - display: table; } - -#error_explanation { - width: 450px; - border: 2px solid red; - padding: 7px; - padding-bottom: 0; - margin-bottom: 20px; - background-color: #f0f0f0; - h2 { - text-align: left; - font-weight: bold; - padding: 5px 5px 5px 15px; - font-size: 12px; - margin: -7px; - margin-bottom: 0px; - background-color: #c00; - color: #fff; } - ul li { - font-size: 12px; - list-style: square; } } diff --git a/app/assets/stylesheets/site.css b/app/assets/stylesheets/site.css index e365e02a..d257675d 100644 --- a/app/assets/stylesheets/site.css +++ b/app/assets/stylesheets/site.css @@ -1,12 +1,12 @@ @charset "UTF-8"; -/* VML ( v\:* don't work for ie8(ie8mode)) ---------------------------------------------------------------------------------------*/ - v\:shape, - v\:image { - behavior: url(#default#VML); - display: block; - } +/* pettanR site.css + * version 0.5.4 + * + * author: + * itozyun + */ + /* Reset --------------------------------------------------------------------------------------*/ @@ -83,82 +83,6 @@ version: 2.7.0 font-family: "MS Pゴシック", Osaka, "ヒラギノ角ゴ Pro W3",sans-serif; } -/* ClearFix ---------------------------------------------------------------------------------------*/ -.clearfix:after { - content: "."; /* 新しい要素を作る */ - display: block; /* ブロックレベル要素に */ - clear: both; - height: 0; - visibility: hidden; -} - -.clearfix { - min-height: 1px; -} - -* html .clearfix { - height: 1px; - /*\*//*/ - height: auto; - overflow: hidden; - /**/ -} - -/* Button ---------------------------------------------------------------------------------------*/ - .button { - border: 1px solid; - background: #E3E3E3; - background: -moz-linear-gradient(center top , #F9F9F9, #E3E3E3); - background: -webkit-gradient(linear, left top, left bottom, from(#F9F9F9), to(#E3E3E3)); - border-color: #ccc #bbb #aaa; - color: #666; - font-weight: bold; - text-align: center; - cursor: pointer; - overflow: hidden; - height: 30px; - line-height: 30px; - border-radius: 3px; - -o-border-radius: 3px; - -ms-border-radius: 3px; - -moz-border-radius: 3px; - -webkit-border-radius: 3px; - } - .button-has-focus { - border-color: #4D90FE; - } - -/* Loading ---------------------------------------------------------------------------------------*/ - .loading { - background-image: url( /assets/loading.gif); - background-position: 50% 50%; - background-repeat: no-repeat; - } - .error { - background-image: url( /assets/error.png); - background-position: 50% 50%; - background-repeat: no-repeat; - } - - - - -/* Noscript Alert ---------------------------------------------------------------------------------------*/ - #noscript-alert { - border-left: 1px solid #666; - display: block; - text-align: center; - color: red; - font-weight: bold; - font-size: 12px; - line-height: 12px; - padding: 11px 0 7px; - } - /* Typography --------------------------------------------------------------------------------------*/ a:link { color:#008;} diff --git a/app/assets/stylesheets/source_pictures.css.scss b/app/assets/stylesheets/source_pictures.css.scss deleted file mode 100644 index d9973ed8..00000000 --- a/app/assets/stylesheets/source_pictures.css.scss +++ /dev/null @@ -1,3 +0,0 @@ -// Place all the styles related to the source_pictures controller here. -// They will automatically be included in application.css. -// You can use Sass (SCSS) here: http://sass-lang.com/ diff --git a/app/assets/stylesheets/speech_baloons.css.scss b/app/assets/stylesheets/speech_baloons.css.scss deleted file mode 100644 index 085a9a21..00000000 --- a/app/assets/stylesheets/speech_baloons.css.scss +++ /dev/null @@ -1,3 +0,0 @@ -// Place all the styles related to the speach_baloons controller here. -// They will automatically be included in application.css. -// You can use Sass (SCSS) here: http://sass-lang.com/ diff --git a/app/assets/stylesheets/speech_templates.css.scss b/app/assets/stylesheets/speech_templates.css.scss deleted file mode 100644 index 7fe46be3..00000000 --- a/app/assets/stylesheets/speech_templates.css.scss +++ /dev/null @@ -1,3 +0,0 @@ -// Place all the styles related to the speach_templates controller here. -// They will automatically be included in application.css. -// You can use Sass (SCSS) here: http://sass-lang.com/ diff --git a/app/assets/stylesheets/speechbaloons.css.scss b/app/assets/stylesheets/speechbaloons.css.scss deleted file mode 100644 index af35a9ec..00000000 --- a/app/assets/stylesheets/speechbaloons.css.scss +++ /dev/null @@ -1,3 +0,0 @@ -// Place all the styles related to the speachbaloons controller here. -// They will automatically be included in application.css. -// You can use Sass (SCSS) here: http://sass-lang.com/ diff --git a/app/assets/stylesheets/speeches.css.scss b/app/assets/stylesheets/speeches.css.scss deleted file mode 100644 index 2b19f3bf..00000000 --- a/app/assets/stylesheets/speeches.css.scss +++ /dev/null @@ -1,3 +0,0 @@ -// Place all the styles related to the speaches controller here. -// They will automatically be included in application.css. -// You can use Sass (SCSS) here: http://sass-lang.com/ diff --git a/app/assets/stylesheets/system.css b/app/assets/stylesheets/system.css index ba6607f4..4944f221 100644 --- a/app/assets/stylesheets/system.css +++ b/app/assets/stylesheets/system.css @@ -1,17 +1,14 @@ @charset "UTF-8"; -/* VML ( v\:* don't work for ie8(ie8mode)) ---------------------------------------------------------------------------------------*/ - v\:shape, - v\:image { - behavior: url(#default#VML); - display: block; - } +/* pettanR system.css + * version 0.5.5 + * + * author: + * itozyun + */ /* Reset --------------------------------------------------------------------------------------*/ - - html, body { margin: 0; padding: 0; @@ -356,4 +353,235 @@ -ms-border-radius: 5px; -moz-border-radius: 5px; -webkit-border-radius: 5px; - } \ No newline at end of file + } + + +/*-------------------------------------------------------------------------------------- + * + * Finder + * + -------------------------------------------------------------------------------------*/ + .finder-body { + position: relative; + overflow: auto; + } + .finder-container .loading { + background-position: 50% bottom; + } + .finder-header { + height: 40px; + position: relative; + background-color: #333; + } + .finder-header ul { + list-style: none; + position: absolute; + top: 0; + left: 48px; + height: 40px; + line-height: 40px; + padding: 0; + margin: 0; + } + .finder-header li { + position: absolute; + top: 0; + left: 0; + height: 40px; + width: 90px; + padding: 0; + margin: 0; + } + .finder-header li a, + .finder-header li a:link, + .finder-header li a:visited { + display: block; + height: 14px; + font-size: 14px; + line-height: 14px; + padding: 16px 0 10px 20px; + margin: 0; + color: #eee; + overflow: hidden; + } + .finder-header li a:hover { + text-decoration: none; + background-color: #66f; + color: #eee; + } + + + .finder-header .button { + position: absolute; + top: 8px; + width: 30px; + height: 24px; + line-height: 24px; + } + .finder-sidebar-switch { + left: 8px; + } + .finder-style-switch { + right: 48px; + } + .finder-action-switch { + right: 8px; + } + + /* Finder Icon + --------------------------------------------------------------------------------------*/ + .finder-icon { + position: relative; + height: 74px; + border-bottom: 1px solid #ccc; + clear: both; + overflow: hidden; /* for webkit */ + } + .finder-icon:hover { + background-color: #eee; + cursor: pointer; + } + .fnder-icon-modern .finder-icon-handle, + .fnder-icon-modern .finder-icon-thumbnail, + .fnder-icon-modern .finder-icon-filename, + .fnder-icon-modern .finder-icon-summary { + display: table-cell; + vertical-align: middle; + line-height: 1.3em; + } + + .finder-icon-handle { + width: 20px; + height: 74px; + } + + .finder-icon-thumbnail { + width: 64px; + height: 74px; + cursor: pointer; + background-repeat: no-repeat; + background-position: 50% 50%; + background-image: url('/assets/sprite.gif'); + } + + .finder-icon .file-type-folder { + background-position: 0 -75px; + } + .finder-icon .file-type-album { + } + .finder-icon .file-type-author { + background-position: -70px -75px; + } + .finder-icon .file-type-comic { + background-position: 0 -145px; + } + .finder-icon .file-type-cabinet { + background-position: -70px -145px; + } + .finder-icon .file-type-panel { + background-position: 0 -215px; + } + .finder-icon .file-type-artist { + background-position: -70px -215px; + } + .finder-icon .file-type-balloon { + background-position: 0 -285px; + } + .finder-icon .file-type-charactor { + background-position: -70px -285px; + } + .has-thumbnail { + } + .fnder-icon-modern .finder-icon-filename { + width: 200px; + padding: 5px 10px; + height: 64px; + font-weight: bold; + color: #333; + } + .fnder-icon-modern .finder-icon-summary { + width: 300px; + padding: 5px 10px; + height: 64px; + color: #666; + } + + /* Finder Icon ie7- + --------------------------------------------------------------------------------------*/ + .finder-icon a, + .finder-icon a:link, + .finder-icon a:visited, + .finder-icon a:active { + display: block; + height: 74px; + text-decoration: none; + zoom: 1; + cursor: pointer; + } + .finder-icon a:hover { + _background-color: #eee; + color: #333; + } + .fnder-icon-ie7 .finder-icon-handle, + .fnder-icon-ie7 .finder-icon-thumbnail { + zoom: 1; + line-height: 1.3em; + } + .finder-icon-cell { + display: inline; + zoom: 1; + } + .finder-icon-vertical-middle-outer { + display: block; + height: 74px; + position: relative; + } + .finder-icon-ie-filename .finder-icon-vertical-middle-outer { + width: 200px; + font-weight: bold; + color: #333; + } + .finder-icon-ie-summary .finder-icon-vertical-middle-outer { + width: 300px; + color: #666; + } + .finder-icon-vertical-middle-inner { + display: block; + position: absolute; + top: 50%; + margin: 0 5px; + } + .fnder-icon-ie7 .finder-icon-filename, + .fnder-icon-ie7 .finder-icon-summary { + position: relative; + top: -50%; + } + + /* Finder Icon Console + --------------------------------------------------------------------------------------*/ + .finder-icon-console { + position: absolute; + top: 0; + right: 0; + } + .finder-icon-console a { + display: block; + width: 74px; + height: 74px; + border-left: 1px solid #ccc; + float: right; + background-image: url('/assets/sprite.gif') !important; + background-repeat: no-repeat; + } + .finder-icon-console a:hover { + background-color: #ccc !important; + } + .finder-icon-console-action { + background-position: 0px -355px; + } + .finder-icon-console-editor-apps { + background-position: -70px -355px; + } + .finder-icon-console-viewer-apps { + background-position: 0px -425px; + } \ No newline at end of file diff --git a/app/assets/stylesheets/system.css.scss b/app/assets/stylesheets/system.css.scss deleted file mode 100644 index 9c5e904b..00000000 --- a/app/assets/stylesheets/system.css.scss +++ /dev/null @@ -1,3 +0,0 @@ -// Place all the styles related to the system controller here. -// They will automatically be included in application.css. -// You can use Sass (SCSS) here: http://sass-lang.com/ diff --git a/app/assets/stylesheets/system_pictures.css.scss b/app/assets/stylesheets/system_pictures.css.scss deleted file mode 100644 index 0d3199b6..00000000 --- a/app/assets/stylesheets/system_pictures.css.scss +++ /dev/null @@ -1,3 +0,0 @@ -// Place all the styles related to the system_pictures controller here. -// They will automatically be included in application.css. -// You can use Sass (SCSS) here: http://sass-lang.com/ diff --git a/config/environments/development.rb b/config/environments/development.rb index 90b48156..51f09cd2 100644 --- a/config/environments/development.rb +++ b/config/environments/development.rb @@ -27,6 +27,9 @@ Pettanr::Application.configure do # Expands the lines which load the assets config.assets.debug = true + + # config.assets.digest = true + # config.static_cache_control = "public, max-age=1" end module Pettanr