Permalink
Browse files

Move sharing templates to action.Share instead of gui.ajax, may have …

…some side-effects, to be tested intensively.
  • Loading branch information...
1 parent 07be14e commit 0451293afe9c9a09214127d789ab7fee0720a82d @cdujeu cdujeu committed Aug 30, 2016
Showing with 208 additions and 221 deletions.
  1. +171 −0 core/src/plugins/action.share/manifest.xml
  2. +37 −221 core/src/plugins/gui.ajax/manifest.xml
@@ -258,6 +258,177 @@
</action>
</actions>
<client_configs>
+ <template name="minisite_orbit" element="ajxp_shared_folder" position="top" label="share_center.153" theme="orbit"><![CDATA[
+ <div id="browser" ajxpClass="AjxpPane" ajxpOptions='{"fit":"height"}'>
+ <div id="logo_widget" class="widget_logo" ajxpClass="LogoWidget" ajxpOptions='{"imageParameter":"gui.ajax/CUSTOM_MINISITE_LOGO"}'></div>
+ <div id="widget_title" ajxpClass="RepositorySimpleLabel" ajxpOptions='{"displayLabelLegend":false,"displayWorkspaceDescription":true}'></div>
+ <div id="breadcrumb" ajxpClass="Breadcrumb" ajxpOptions='{}'></div>
+ <div id="files_list_header">
+ <div id="display_toolbar" ajxpClass="ActionsToolbar" ajxpOptions='{"submenuClassName":"panelHeaderMenu","submenuPosition":"bottom right","submenuOffsetTop":12,"toolbarsList":["content_pane-actions"],"skipBubbling":true, "skipCarousel":true,"submenuOffsetTop":2}'></div>
+ <div id="buttons_bar" class="action_bar" ajxpClass="ActionsToolbar" ajxpOptions='{"toolbarsList":["navigation","minisite", "inline"],"skipBubbling":true, "skipCarousel":true,"submenuOffsetTop":2}'></div>
+ </div>
+ <div id="cpane_container1" ajxpClass="AjxpPane" ajxpOptions='{"fit":"height","fitParent":"browser"}'>
+ <div id="content_pane" ajxpClass="FilesList" ajxpOptions='{"displayMode":"detail", "detailThumbSize": 50 ,"replaceScroller":true, "messageBoxReference":true, "fit":"height", "fitParent":"cpane_container1", "cellPaddingCorrection":6, "iconBgPosition" : "5px 4px", "invisibleSelection":false}' style="border: 1px solid #bbb; border-width:0 1px;"></div>
+ </div>
+ </div>
+ <script>
+ document.observe("ajaxplorer:afterApply-login", function(){
+ AjxpPane.prototype.staticApplyBackgroundFromConfigs($("overlay"), "gui.ajax/CUSTOM_SHAREPAGE_BACKGROUND_", "display:block;", true);
+ });
+ </script>
+ ]]></template>
+ <template name="minisite_film_strip" element="ajxp_film_strip" position="top" label="share_center.154" theme="orbit"><![CDATA[
+ <div id="browser" ajxpClass="AjxpPane" ajxpOptions='{"fit":"height"}'>
+ <div id="logo_widget" class="widget_logo" ajxpClass="LogoWidget" ajxpOptions='{"imageParameter":"gui.ajax/CUSTOM_MINISITE_LOGO"}'></div>
+ <div id="widget_title" ajxpClass="RepositorySimpleLabel" ajxpOptions='{"displayLabelLegend":false,"displayWorkspaceDescription":true}'></div>
+ <div id="cpane_container" ajxpClass="AjxpPane" ajxpOptions='{"fit":"height","fitParent":"browser", "fitMarginBottom":80}'>
+ <div id="cpane_header" class="panelHeader">
+ <div id="display_toolbar" ajxpClass="ActionsToolbar" ajxpOptions='{"submenuClassName":"panelHeaderMenu","submenuPosition":"bottom right","submenuOffsetTop":12,"toolbarsList":["minisite", "inline"],"skipBubbling":true, "skipCarousel":true,"submenuOffsetTop":2}'></div>
+ <div id="breadcrumb" ajxpClass="Breadcrumb" style="width:50%;" ajxpOptions='{"flexTo":"cpane_header", "flexToMargin":50, "resize_events":["actions_refreshed"]}'></div>
+ </div>
+ <div id="cpane_tabs" ajxpClass="AjxpTabulator" ajxpOptions='{"fit":"height", "fitParent":"cpane_container","registerAsEditorOpener":true, "saveState":false, "defaultTabId": "","tabInfos" : [], "uniqueTab":true}'></div>
+ <div id="content_pane" ajxpClass="FilesList" ajxpOptions='{"displayMode":"thumb", "fixedDisplayMode":"thumb", "fixedThumbSize":60,"replaceScroller":false, "horizontalScroll":true, "messageBoxReference":true, "fit":"content", "fitParent":"cpane_container", "cellPaddingCorrection":6, "iconBgPosition" : "5px 4px", "invisibleSelection":false}'></div>
+ </div>
+ </div>
+ <script>
+ document.observe("ajaxplorer:afterApply-login", function(){
+ AjxpPane.prototype.staticApplyBackgroundFromConfigs($("overlay"), "gui.ajax/CUSTOM_SHAREPAGE_BACKGROUND_", "display:block;", true);
+ });
+ document.observe("ajaxplorer:selection_changed", function(e){
+ try{
+ var dm = ajaxplorer.getContextHolder();
+ var nodes = dm.getSelectedNodes();
+ if(nodes[0].isLeaf() && e.memo._selectionSource.__className == 'FilesList'){
+ window.setTimeout(function(){pydio.getController().fireDefaultAction("file");}, 1);
+ }
+ }catch(e){}
+ });
+ var p;
+ document.observe("ajaxplorer:user_logged", function(){
+ if(p) return;
+ try{
+ p = new PeriodicalExecuter(function(){
+ var dm = ajaxplorer.getContextHolder();
+ if(dm.getSelectedNodes().length){
+ p.stop();
+ return;
+ }
+ var first = dm.getRootNode().getFirstChildIfExists();
+ if(first){
+ dm.setSelectedNodes([first], "dataModel");
+ window.setTimeout(function(){pydio.getController().fireDefaultAction("file");}, 1);
+ p.stop();
+ return;
+ }
+ }, 1);
+ }catch(e){}
+ });
+ </script>
+ ]]></template>
+ <template name="unique_preview_file" element="ajxp_unique_strip" position="top" label="Unique File Preview"><![CDATA[
+ <div id="browser" ajxpClass="AjxpPane" ajxpOptions='{"fit":"height"}'>
+ <div id="logo_widget" class="widget_logo" ajxpClass="LogoWidget" ajxpOptions='{"imageParameter":"gui.ajax/CUSTOM_MINISITE_LOGO"}'></div>
+ <div id="display_toolbar" ajxpClass="ActionsToolbar" ajxpOptions='{"submenuClassName":"panelHeaderMenu","submenuPosition":"bottom right","submenuOffsetTop":12,"toolbarsList":["inline", "minisite-share-actions"],"skipBubbling":true, "skipCarousel":true,"submenuOffsetTop":2}'></div>
+ <div id="widget_title" style="padding: 28px 0 22px 20px;" ajxpClass="RepositorySimpleLabel" ajxpOptions='{"displayLabelLegend":false,"displayWorkspaceDescription":true}'></div>
+ <div id="cpane_container" ajxpClass="AjxpPane" ajxpOptions='{"fit":"height","fitParent":"browser"}'>
+ <div id="cpane_tabs" ajxpClass="AjxpTabulator" ajxpOptions='{"fit":"height", "fitParent":"cpane_container","registerAsEditorOpener":true, "saveState":false, "defaultTabId": "","tabInfos" : [], "uniqueTab":true}'></div>
+ </div>
+ </div>
+ <script>
+ document.observe("ajaxplorer:afterApply-login", function(){
+ AjxpPane.prototype.staticApplyBackgroundFromConfigs($("overlay"), "gui.ajax/CUSTOM_SHAREPAGE_BACKGROUND_", "display:block;", true);
+ });
+ document.observe("ajaxplorer:user_logged", function(){
+ try{
+
+ var p = new PeriodicalExecuter(function(){
+ var dm = ajaxplorer.getContextHolder();
+ if(dm.getSelectedNodes().length){
+ p.stop();
+ return;
+ }
+ var root = dm.getRootNode();
+ var first = root.getFirstChildIfExists();
+ if(first){
+ if((first.getAjxpMime() == 'mp3' || first.getAjxpMime() == 'wav') && !(window.soundManager && window.soundManager.enabled)){
+ return;
+ }
+ dm.setSelectedNodes([first], "dataModel");
+ window.setTimeout(function(){pydio.getController().fireDefaultAction("file");}, 1);
+ p.stop();
+ return;
+ }
+ }, 1);
+ }catch(e){
+ if (console) console.log(e);
+ }
+ });
+ </script>
+ ]]></template>
+ <template name="unique_preview_download" element="ajxp_unique_dl" position="top" label="Big download button"><![CDATA[
+ <div id="browser" ajxpClass="AjxpPane" ajxpOptions='{"fit":"height"}'>
+ <div id="background_container" ajxpClass="AjxpPane" ajxpOptions='{"imageBackgroundFromConfigs":"gui.ajax/CUSTOM_SHAREPAGE_BACKGROUND_"}'></div>
+ <div id="cpane_container" ajxpClass="AjxpPane" ajxpOptions='{"fit":"height","fitParent":"browser"}'>
+ <div id="logo_widget" class="widget_logo" ajxpClass="LogoWidget" ajxpOptions='{"imageParameter":"gui.ajax/CUSTOM_MINISITE_LOGO"}'></div>
+ <div id="widget_title" ajxpClass="RepositorySimpleLabel" ajxpOptions='{"displayLabelLegend":false,"displayWorkspaceDescription":true}'>
+ </div>
+ <div id="dl_toolbar" ajxpClass="ActionsToolbar" ajxpOptions='{"toolbarsList":["inline"], "skipCarousel":true}'></div>
+ <div id="share_toolbar" ajxpClass="ActionsToolbar" ajxpOptions='{"toolbarsList":["minisite-share-actions"], "skipCarousel":true}'></div>
+ </div>
+ </div>
+ <script>
+ document.observe("ajaxplorer:user_logged", function(){
+ try{
+
+ var p = new PeriodicalExecuter(function(){
+ var dm = ajaxplorer.getContextHolder();
+ if(dm.getSelectedNodes().length){
+ p.stop();
+ return;
+ }
+ var first = dm.getRootNode().getFirstChildIfExists();
+ if(first){
+ dm.setSelectedNodes([first], "dataModel");
+ p.stop();
+ return;
+ }
+ }, 1);
+ }catch(e){
+ if (console) console.log(e);
+ }
+ });
+ </script>
+ ]]></template>
+ <template name="minisite_bare" element="ajxp_embed_template" position="top" label="share_center.155"><![CDATA[
+ <div id="browser" ajxpClass="AjxpPane" ajxpOptions='{"fit":"height"}'>
+ <div id="cpane_header" class="panelHeader">
+ <div id="display_toolbar" ajxpClass="ActionsToolbar" ajxpOptions='{"submenuClassName":"panelHeaderMenu","submenuPosition":"bottom right","submenuOffsetTop":12,"toolbarsList":["navigation", "minisite", "inline", "content_pane-actions"],"skipBubbling":true, "skipCarousel":true,"submenuOffsetTop":2}'></div>
+ <div id="breadcrumb" ajxpClass="Breadcrumb" style="width:50%;" ajxpOptions='{"flexTo":"cpane_header", "flexToMargin":30}'></div>
+ </div>
+ <div id="content_pane" ajxpClass="FilesList" ajxpOptions='{"displayMode":"detail", "detailThumbSize": 50 ,"replaceScroller":true, "messageBoxReference":true, "fit":"height", "fitParent":"cpane_container", "cellPaddingCorrection":6, "iconBgPosition" : "5px 4px", "invisibleSelection":false}' style="border: 1px solid #bbb; border-width:0 1px;"></div>
+ <div id="logo_widget" class="widget_logo" ajxpClass="LogoWidget" ajxpOptions='{"imageParameter":"gui.ajax/CUSTOM_MINISITE_LOGO"}'></div>
+ </div>
+ <script>
+ document.observe("ajaxplorer:afterApply-login", function(){
+ AjxpPane.prototype.staticApplyBackgroundFromConfigs($("overlay"), "gui.ajax/CUSTOM_SHAREPAGE_BACKGROUND_", "display:block;", true);
+ });
+ </script>
+ ]]></template>
+ <template name="minisite_dropbox" element="ajxp_dropbox_template" position="top" label="share_center.163"><![CDATA[
+ <div id="browser" ajxpClass="AjxpPane" ajxpOptions='{"fit":"height"}'>
+ <div id="cpane_header" class="panelHeader">
+ <div id="display_toolbar" ajxpClass="ActionsToolbar" ajxpOptions='{"submenuClassName":"panelHeaderMenu","submenuPosition":"bottom right","submenuOffsetTop":12,"toolbarsList":["minisite", "inline","content_pane-actions"],"skipBubbling":true, "skipCarousel":true,"submenuOffsetTop":2}'></div>
+ <div id="breadcrumb" ajxpClass="Breadcrumb" style="width:50%;" ajxpOptions='{"flexTo":"cpane_header", "flexToMargin":30}'></div>
+ </div>
+ <div id="content_pane" ajxpClass="FilesList" ajxpOptions='{"displayMode":"detail", "detailThumbSize": 50 ,"replaceScroller":true, "messageBoxReference":true, "fit":"height", "fitParent":"cpane_container", "cellPaddingCorrection":6, "iconBgPosition" : "5px 4px", "invisibleSelection":false}' style="border: 1px solid #bbb; border-width:0 1px;"></div>
+ <div id="logo_widget" class="widget_logo" ajxpClass="LogoWidget" ajxpOptions='{"imageParameter":"gui.ajax/CUSTOM_MINISITE_LOGO"}'></div>
+ </div>
+ <script>
+ document.observe("ajaxplorer:afterApply-login", function(){
+ AjxpPane.prototype.staticApplyBackgroundFromConfigs($("overlay"), "gui.ajax/CUSTOM_SHAREPAGE_BACKGROUND_", "display:block;", true);
+ });
+ </script>
+ ]]></template>
<component_config className="InfoPanel">
<infoPanelExtension mime="meta:ajxp_shared" attributes="" modifier="ShareInfoPanel.loader">
<messages>
Oops, something went wrong.

0 comments on commit 0451293

Please sign in to comment.