portals-jetspeed-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From smi...@apache.org
Subject svn commit: r583998 [1/4] - /portals/jetspeed-2/branches/JETSPEED-2.1.3/src/webapp/javascript/jetspeed/widget/
Date Fri, 12 Oct 2007 00:36:13 GMT
Author: smilek
Date: Thu Oct 11 17:36:12 2007
New Revision: 583998

URL: http://svn.apache.org/viewvc?rev=583998&view=rev
Log:
continuation of desktop overhaul

Modified:
    portals/jetspeed-2/branches/JETSPEED-2.1.3/src/webapp/javascript/jetspeed/widget/EditorTable.src.js
    portals/jetspeed-2/branches/JETSPEED-2.1.3/src/webapp/javascript/jetspeed/widget/LayoutEditPane.css
    portals/jetspeed-2/branches/JETSPEED-2.1.3/src/webapp/javascript/jetspeed/widget/LayoutEditPane.html
    portals/jetspeed-2/branches/JETSPEED-2.1.3/src/webapp/javascript/jetspeed/widget/LayoutEditPane.js
    portals/jetspeed-2/branches/JETSPEED-2.1.3/src/webapp/javascript/jetspeed/widget/LayoutEditPane.src.js
    portals/jetspeed-2/branches/JETSPEED-2.1.3/src/webapp/javascript/jetspeed/widget/PageEditPane.css
    portals/jetspeed-2/branches/JETSPEED-2.1.3/src/webapp/javascript/jetspeed/widget/PageEditPane.html
    portals/jetspeed-2/branches/JETSPEED-2.1.3/src/webapp/javascript/jetspeed/widget/PageEditPane.js
    portals/jetspeed-2/branches/JETSPEED-2.1.3/src/webapp/javascript/jetspeed/widget/PageEditPane.src.js
    portals/jetspeed-2/branches/JETSPEED-2.1.3/src/webapp/javascript/jetspeed/widget/PageEditor.css
    portals/jetspeed-2/branches/JETSPEED-2.1.3/src/webapp/javascript/jetspeed/widget/PageEditor.html
    portals/jetspeed-2/branches/JETSPEED-2.1.3/src/webapp/javascript/jetspeed/widget/PageEditor.js
    portals/jetspeed-2/branches/JETSPEED-2.1.3/src/webapp/javascript/jetspeed/widget/PageEditor.src.js
    portals/jetspeed-2/branches/JETSPEED-2.1.3/src/webapp/javascript/jetspeed/widget/PortalTooltipManager.js
    portals/jetspeed-2/branches/JETSPEED-2.1.3/src/webapp/javascript/jetspeed/widget/PortalTooltipManager.src.js
    portals/jetspeed-2/branches/JETSPEED-2.1.3/src/webapp/javascript/jetspeed/widget/PortletWindow.css
    portals/jetspeed-2/branches/JETSPEED-2.1.3/src/webapp/javascript/jetspeed/widget/PortletWindow.js
    portals/jetspeed-2/branches/JETSPEED-2.1.3/src/webapp/javascript/jetspeed/widget/PortletWindow.src.js

Modified: portals/jetspeed-2/branches/JETSPEED-2.1.3/src/webapp/javascript/jetspeed/widget/EditorTable.src.js
URL: http://svn.apache.org/viewvc/portals/jetspeed-2/branches/JETSPEED-2.1.3/src/webapp/javascript/jetspeed/widget/EditorTable.src.js?rev=583998&r1=583997&r2=583998&view=diff
==============================================================================
--- portals/jetspeed-2/branches/JETSPEED-2.1.3/src/webapp/javascript/jetspeed/widget/EditorTable.src.js (original)
+++ portals/jetspeed-2/branches/JETSPEED-2.1.3/src/webapp/javascript/jetspeed/widget/EditorTable.src.js Thu Oct 11 17:36:12 2007
@@ -1,318 +1,318 @@
-/*
+/*
  * Licensed to the Apache Software Foundation (ASF) under one or more
  * contributor license agreements.  See the NOTICE file distributed with
  * this work for additional information regarding copyright ownership.
  * The ASF licenses this file to You under the Apache License, Version 2.0
  * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- * 
- *      http://www.apache.org/licenses/LICENSE-2.0
- * 
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- *
- * author: Steve Milek
- */
-
-dojo.provide("jetspeed.widget.EditorTable");
-
-dojo.require("dojo.widget.SortableTable");
-
-jetspeed.widget.EditorTable = function()
-{
-    dojo.widget.SortableTable.call(this);
-    this.widgetType = "EditorTable";
-    this.headerSortUpClass="selectedUp";
-	this.headerSortDownClass="selectedDown";
-};
-
-dojo.inherits( jetspeed.widget.EditorTable, dojo.widget.SortableTable);
-
-dojo.lang.extend( jetspeed.widget.EditorTable, {
-    saveWarningDialogWidgetId: null,
-    
-    /* derived class protocol - attach-to or override this methods */
-    updateEditor: function( rowData )
-    {
-
-    },
-    saveEntrySubmit: function( selectedRowData, /* boolean */ removeEntry )
-    {
-
-    },
-    clearAndDisableEditor: function()
-    {
-
-    },
-    getNewEntryPrototype: function()
-    {
-        return {};
-    },
-    
-    /* base class protocol */
-    render: function(bDontPreserve)
-    {
-        bDontPreserve = true;    // for EditorTable, all calls to render should not reset data (i.e. call SortableTable.parseDataFromTable())
-        jetspeed.widget.EditorTable.superclass.render.call( this, bDontPreserve );
-    },
-
-    buildRendering: function(args, frag)
-    {
-        jetspeed.widget.EditorTable.superclass.buildRendering.call( this, args, frag );
-        if ( args.templateCssPath )
-        {
-            dojo.html.insertCssFile( dojo.uri.dojoUri(args.templateCssPath), document, true );
-        }
-    },
-
-
-    /* methods */
-    hasRowChanged: function( rowData )
-    {
-        if ( ! rowData ) return false;
-        var tId = rowData.Id;
-        var masterData = this.getData( this.js_masterdata, tId );
-        var changed = ( rowData.__isNew || rowData.__isModified ) ? true : false;
-        if ( ! changed )
-        {
-            for ( var slotKey in masterData )
-            {
-                if ( rowData[ slotKey ] != masterData[ slotKey ] )
-                {
-                    //dojo.debug( "slot " + slotKey + " changed - old: " + masterData[ slotKey ] + " new: " + rowData[ slotKey ] ) ;
-                    changed = true;
-                    break;
-                }
-            }
-        }
-        return changed;
-    },
-    entryIsNew: function( rowData )
-    {
-        if ( ! rowData ) return false;
-        return rowData.__isNew ;
-    },
-    setModified: function( rowData )
-    {
-        if ( ! rowData ) return;
-        rowData.__isModified = true;
-    },
-    getSelectedRow: function()
-    {
-        if ( this.selected && this.selected.length == 1 )
-        {
-            var tId = this.selected[0].Id;
-            var data = this.getData( this.data, tId );
-            return data;
-        }
-        return null;
-    },
-    getData: function( tableWidgetData, matchId )
-    {
-        if ( ! tableWidgetData ) return null ;
-        for( var i = 0 ; i < tableWidgetData.length; i++ )
-        {
-            if ( tableWidgetData[ i ].Id == matchId )
-            {
-                return tableWidgetData[ i ];
-            }
-        }
-        return null;
-    },
-    getDataIndex: function( tableWidgetData, matchId )
-    {
-        if ( ! tableWidgetData ) return -1;
-        for( var i = 0 ; i < tableWidgetData.length; i++ )
-        {
-            if ( tableWidgetData[ i ].Id == matchId )
-            {
-                return i;
-            }
-        }
-        return -1;
-    },
-    processTableRowEvent: function( e )
-    {
-        var row = dojo.html.getParentByType( e.target, "tr" );
-        var rowData = this.getObjectFromRow( row );
-        this.updateEditor( rowData );
-    },
-
-    checkForChanges: function()
-    {
-        var selectedRowData = this.getSelectedRow();
-    
-        if ( ! selectedRowData ) return false;
-        var hasChanged = this.hasRowChanged( selectedRowData );
-        return ( ! hasChanged ? false : ( selectedRowData.__isNew ? "new" : "modified" ) );
-    },
-
-    updateClonedData: function( fromData, toData )
-    {
-        if ( ! fromData || ! toData ) return;
-        for ( var slotKey in fromData )
-        {
-            toData[ slotKey ] = fromData[ slotKey ];
-        }
-    },
-
-    printSelection: function()
-    {
-        if ( this.selected && this.selected.length == 1 )
-            dojo.debug( this.widgetId + " selection: " + jsDebugShallow( this.selected[0] ) );
-        else
-            dojo.debug( this.widgetId + " selection: null" );
-    },
-
-    newEntry: function()
-    {
-        if ( this.saveWarningDialogWidgetId )
-        {
-            if ( this.checkForChanges() )
-            {
-                dojo.widget.byId( this.saveWarningDialogWidgetId ).show();
-                return;
-            }
-        }
-    
-        var newEntry = dojo.lang.shallowCopy( this.getNewEntryPrototype() );
-        var tId = 1;
-        for ( var i = 0 ; i < this.js_masterdata.length; i++ )
-        {
-            if ( this.js_masterdata[i].Id >= tId )
-                tId = this.js_masterdata[i].Id + 1;
-        }
-        newEntry.Id = tId;
-        this.js_masterdata.push( dojo.lang.shallowCopy( newEntry ) );
-        newEntry.__isNew = true;
-        this.data.push( newEntry );
-        this.selected = [ dojo.lang.shallowCopy( newEntry ) ];
-
-        this.render(true);
-        this.showSelections();
-
-        this.updateEditor( newEntry );
-    },
-
-    deleteEntry: function()
-    {
-        var selectedRowData = this.getSelectedRow();
-    
-        if ( ! selectedRowData ) return;
-        var tId = selectedRowData.Id;
-    
-        if ( ! selectedRowData.__isNew  )
-            this.saveEntrySubmit( selectedRowData, true );
-
-        var tIndex = this.getDataIndex( this.js_masterdata, tId );
-        if ( tIndex != -1 )
-            this.js_masterdata.splice( tIndex, 1 );
-
-        tIndex = this.getDataIndex( this.data, tId );
-        if ( tIndex != -1 )
-            this.data.splice( tIndex, 1 );
-
-        this.selected = [];
-        this.render(true);
-        this.showSelections();
-    
-        this.clearAndDisableEditor();
-    },
-    saveEntry: function()
-    {
-        var selectedRowData = this.getSelectedRow();
-
-        if ( ! selectedRowData ) { dojo.raise( "saveEntry can't find selectedRowData" ) ; return; } 
-        var masterData = this.getData( this.js_masterdata, selectedRowData.Id );
-        if ( ! masterData ) { dojo.raise( "saveEntry can't find masterdata" ) ; return; } 
-
-        this.saveEntrySubmit( selectedRowData );
-
-        //delete masterData.__isNew;
-        //delete masterData.__isModified;
-        delete selectedRowData.__isNew;
-        delete selectedRowData.__isModified;
-        this.updateClonedData( selectedRowData, masterData );
-        this.updateClonedData( selectedRowData, this.selected[0] );
-        this.updateEditor( selectedRowData );
-    },
-
-    revertEntry: function()
-    {
-        var selectedRowData = this.getSelectedRow();
-    
-        if ( ! selectedRowData ) return;
-
-        if ( selectedRowData.__isNew )
-        {
-            deleteEntry();
-        }
-        else
-        {
-            delete selectedRowData.__isModified;
-            var masterData = this.getData( this.js_masterdata, selectedRowData.Id );
-            if ( ! masterData ) return;
-            this.updateClonedData( masterData, selectedRowData );
-            this.updateClonedData( masterData, this.selected[0] );
-            this.render(true);
-            this.showSelections();
-            this.updateEditor( masterData );
-        }
-    },
-
-    okToChangeSelectionOrExit: function( invocation )   // listSelectionChangeOk
-    {
-        if ( this.checkForChanges() )
-        {
-            if ( this.saveWarningDialogWidgetId )
-            {
-                dojo.widget.byId( this.saveWarningDialogWidgetId ).show();
-                return false;
-            }
-            else
-            {
-                this.saveEntry();
-            }
-        }
-        if ( invocation != null )
-            invocation.proceed();
-        return true;
-    },
-
-    dojoDebugTableData: function()
-    {
-        dojo.debug( debugTableData() );
-    },
-    debugTableData: function()
-    {
-        var tTableWidget = this;
-        // format: js_masterdata[index][key]=value (data[index][key]
-        buff = tTableWidget.widgetId + " data:" + "\r\n";
-        for ( var masterDataIndex = 0 ; masterDataIndex < tTableWidget.js_masterdata.length ; masterDataIndex++ )
-        {
-            buff += "[" + masterDataIndex + "]" + "\r\n";
-            var slotsUsed = new Object();
-            for ( var slotKey in tTableWidget.js_masterdata[masterDataIndex] )
-            {
-                buff += "   " + slotKey + "=" + tTableWidget.js_masterdata[masterDataIndex][ slotKey ];
-                if ( slotKey == "__isModified" || slotKey == "__isNew" )
-                    buff += "\r\n";
-                else
-                {
-                    var dataVal = null;
-                    if ( tTableWidget.data.length <= masterDataIndex )
-                       buff += " <out-of-bounds>" + "\r\n";
-                    else
-                    {
-                       dataVal = tTableWidget.data[masterDataIndex][ slotKey ];
-                       buff += " (" + ( dataVal == null ? "null" : dataVal ) + ")" + "\r\n";
-                    }
-                }
-            }
-        }
-        return buff;
-    }
-});
+ * the License.  You may obtain a copy of the License at
+ * 
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ * 
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ *
+ * author: Steve Milek
+ */
+
+dojo.provide("jetspeed.widget.EditorTable");
+
+dojo.require("dojo.widget.SortableTable");
+
+jetspeed.widget.EditorTable = function()
+{
+    dojo.widget.SortableTable.call(this);
+    this.widgetType = "EditorTable";
+    this.headerSortUpClass="selectedUp";
+	this.headerSortDownClass="selectedDown";
+};
+
+dojo.inherits( jetspeed.widget.EditorTable, dojo.widget.SortableTable);
+
+dojo.lang.extend( jetspeed.widget.EditorTable, {
+    saveWarningDialogWidgetId: null,
+    
+    /* derived class protocol - attach-to or override this methods */
+    updateEditor: function( rowData )
+    {
+
+    },
+    saveEntrySubmit: function( selectedRowData, /* boolean */ removeEntry )
+    {
+
+    },
+    clearAndDisableEditor: function()
+    {
+
+    },
+    getNewEntryPrototype: function()
+    {
+        return {};
+    },
+    
+    /* base class protocol */
+    render: function(bDontPreserve)
+    {
+        bDontPreserve = true;    // for EditorTable, all calls to render should not reset data (i.e. call SortableTable.parseDataFromTable())
+        jetspeed.widget.EditorTable.superclass.render.call( this, bDontPreserve );
+    },
+
+    buildRendering: function(args, frag)
+    {
+        jetspeed.widget.EditorTable.superclass.buildRendering.call( this, args, frag );
+        if ( args.templateCssPath )
+        {
+            dojo.html.insertCssFile( dojo.uri.dojoUri(args.templateCssPath), document, true );
+        }
+    },
+
+
+    /* methods */
+    hasRowChanged: function( rowData )
+    {
+        if ( ! rowData ) return false;
+        var tId = rowData.Id;
+        var masterData = this.getData( this.js_masterdata, tId );
+        var changed = ( rowData.__isNew || rowData.__isModified ) ? true : false;
+        if ( ! changed )
+        {
+            for ( var slotKey in masterData )
+            {
+                if ( rowData[ slotKey ] != masterData[ slotKey ] )
+                {
+                    //dojo.debug( "slot " + slotKey + " changed - old: " + masterData[ slotKey ] + " new: " + rowData[ slotKey ] ) ;
+                    changed = true;
+                    break;
+                }
+            }
+        }
+        return changed;
+    },
+    entryIsNew: function( rowData )
+    {
+        if ( ! rowData ) return false;
+        return rowData.__isNew ;
+    },
+    setModified: function( rowData )
+    {
+        if ( ! rowData ) return;
+        rowData.__isModified = true;
+    },
+    getSelectedRow: function()
+    {
+        if ( this.selected && this.selected.length == 1 )
+        {
+            var tId = this.selected[0].Id;
+            var data = this.getData( this.data, tId );
+            return data;
+        }
+        return null;
+    },
+    getData: function( tableWidgetData, matchId )
+    {
+        if ( ! tableWidgetData ) return null ;
+        for( var i = 0 ; i < tableWidgetData.length; i++ )
+        {
+            if ( tableWidgetData[ i ].Id == matchId )
+            {
+                return tableWidgetData[ i ];
+            }
+        }
+        return null;
+    },
+    getDataIndex: function( tableWidgetData, matchId )
+    {
+        if ( ! tableWidgetData ) return -1;
+        for( var i = 0 ; i < tableWidgetData.length; i++ )
+        {
+            if ( tableWidgetData[ i ].Id == matchId )
+            {
+                return i;
+            }
+        }
+        return -1;
+    },
+    processTableRowEvent: function( e )
+    {
+        var row = dojo.html.getParentByType( e.target, "tr" );
+        var rowData = this.getObjectFromRow( row );
+        this.updateEditor( rowData );
+    },
+
+    checkForChanges: function()
+    {
+        var selectedRowData = this.getSelectedRow();
+    
+        if ( ! selectedRowData ) return false;
+        var hasChanged = this.hasRowChanged( selectedRowData );
+        return ( ! hasChanged ? false : ( selectedRowData.__isNew ? "new" : "modified" ) );
+    },
+
+    updateClonedData: function( fromData, toData )
+    {
+        if ( ! fromData || ! toData ) return;
+        for ( var slotKey in fromData )
+        {
+            toData[ slotKey ] = fromData[ slotKey ];
+        }
+    },
+
+    printSelection: function()
+    {
+        if ( this.selected && this.selected.length == 1 )
+            dojo.debug( this.widgetId + " selection: " + jsDebugShallow( this.selected[0] ) );
+        else
+            dojo.debug( this.widgetId + " selection: null" );
+    },
+
+    newEntry: function()
+    {
+        if ( this.saveWarningDialogWidgetId )
+        {
+            if ( this.checkForChanges() )
+            {
+                dojo.widget.byId( this.saveWarningDialogWidgetId ).show();
+                return;
+            }
+        }
+    
+        var newEntry = dojo.lang.shallowCopy( this.getNewEntryPrototype() );
+        var tId = 1;
+        for ( var i = 0 ; i < this.js_masterdata.length; i++ )
+        {
+            if ( this.js_masterdata[i].Id >= tId )
+                tId = this.js_masterdata[i].Id + 1;
+        }
+        newEntry.Id = tId;
+        this.js_masterdata.push( dojo.lang.shallowCopy( newEntry ) );
+        newEntry.__isNew = true;
+        this.data.push( newEntry );
+        this.selected = [ dojo.lang.shallowCopy( newEntry ) ];
+
+        this.render(true);
+        this.showSelections();
+
+        this.updateEditor( newEntry );
+    },
+
+    deleteEntry: function()
+    {
+        var selectedRowData = this.getSelectedRow();
+    
+        if ( ! selectedRowData ) return;
+        var tId = selectedRowData.Id;
+    
+        if ( ! selectedRowData.__isNew  )
+            this.saveEntrySubmit( selectedRowData, true );
+
+        var tIndex = this.getDataIndex( this.js_masterdata, tId );
+        if ( tIndex != -1 )
+            this.js_masterdata.splice( tIndex, 1 );
+
+        tIndex = this.getDataIndex( this.data, tId );
+        if ( tIndex != -1 )
+            this.data.splice( tIndex, 1 );
+
+        this.selected = [];
+        this.render(true);
+        this.showSelections();
+    
+        this.clearAndDisableEditor();
+    },
+    saveEntry: function()
+    {
+        var selectedRowData = this.getSelectedRow();
+
+        if ( ! selectedRowData ) { dojo.raise( "saveEntry can't find selectedRowData" ) ; return; } 
+        var masterData = this.getData( this.js_masterdata, selectedRowData.Id );
+        if ( ! masterData ) { dojo.raise( "saveEntry can't find masterdata" ) ; return; } 
+
+        this.saveEntrySubmit( selectedRowData );
+
+        //delete masterData.__isNew;
+        //delete masterData.__isModified;
+        delete selectedRowData.__isNew;
+        delete selectedRowData.__isModified;
+        this.updateClonedData( selectedRowData, masterData );
+        this.updateClonedData( selectedRowData, this.selected[0] );
+        this.updateEditor( selectedRowData );
+    },
+
+    revertEntry: function()
+    {
+        var selectedRowData = this.getSelectedRow();
+    
+        if ( ! selectedRowData ) return;
+
+        if ( selectedRowData.__isNew )
+        {
+            deleteEntry();
+        }
+        else
+        {
+            delete selectedRowData.__isModified;
+            var masterData = this.getData( this.js_masterdata, selectedRowData.Id );
+            if ( ! masterData ) return;
+            this.updateClonedData( masterData, selectedRowData );
+            this.updateClonedData( masterData, this.selected[0] );
+            this.render(true);
+            this.showSelections();
+            this.updateEditor( masterData );
+        }
+    },
+
+    okToChangeSelectionOrExit: function( invocation )   // listSelectionChangeOk
+    {
+        if ( this.checkForChanges() )
+        {
+            if ( this.saveWarningDialogWidgetId )
+            {
+                dojo.widget.byId( this.saveWarningDialogWidgetId ).show();
+                return false;
+            }
+            else
+            {
+                this.saveEntry();
+            }
+        }
+        if ( invocation != null )
+            invocation.proceed();
+        return true;
+    },
+
+    dojoDebugTableData: function()
+    {
+        dojo.debug( debugTableData() );
+    },
+    debugTableData: function()
+    {
+        var tTableWidget = this;
+        // format: js_masterdata[index][key]=value (data[index][key]
+        buff = tTableWidget.widgetId + " data:" + "\r\n";
+        for ( var masterDataIndex = 0 ; masterDataIndex < tTableWidget.js_masterdata.length ; masterDataIndex++ )
+        {
+            buff += "[" + masterDataIndex + "]" + "\r\n";
+            var slotsUsed = new Object();
+            for ( var slotKey in tTableWidget.js_masterdata[masterDataIndex] )
+            {
+                buff += "   " + slotKey + "=" + tTableWidget.js_masterdata[masterDataIndex][ slotKey ];
+                if ( slotKey == "__isModified" || slotKey == "__isNew" )
+                    buff += "\r\n";
+                else
+                {
+                    var dataVal = null;
+                    if ( tTableWidget.data.length <= masterDataIndex )
+                       buff += " <out-of-bounds>" + "\r\n";
+                    else
+                    {
+                       dataVal = tTableWidget.data[masterDataIndex][ slotKey ];
+                       buff += " (" + ( dataVal == null ? "null" : dataVal ) + ")" + "\r\n";
+                    }
+                }
+            }
+        }
+        return buff;
+    }
+});

Modified: portals/jetspeed-2/branches/JETSPEED-2.1.3/src/webapp/javascript/jetspeed/widget/LayoutEditPane.css
URL: http://svn.apache.org/viewvc/portals/jetspeed-2/branches/JETSPEED-2.1.3/src/webapp/javascript/jetspeed/widget/LayoutEditPane.css?rev=583998&r1=583997&r2=583998&view=diff
==============================================================================
--- portals/jetspeed-2/branches/JETSPEED-2.1.3/src/webapp/javascript/jetspeed/widget/LayoutEditPane.css (original)
+++ portals/jetspeed-2/branches/JETSPEED-2.1.3/src/webapp/javascript/jetspeed/widget/LayoutEditPane.css Thu Oct 11 17:36:12 2007
@@ -18,8 +18,6 @@
 .layoutEditPane { position: relative; width: 100% }  
 /*   ^^^ width: 100% is need to avoid IE auto-containing bug: http://www.satzansatz.de/cssd/rpfloat.html */
 
-.layoutEditPane .container{ }
-
 .layoutEditPane label,
 .layoutEditPane input,
 .layoutEditPane select

Modified: portals/jetspeed-2/branches/JETSPEED-2.1.3/src/webapp/javascript/jetspeed/widget/LayoutEditPane.html
URL: http://svn.apache.org/viewvc/portals/jetspeed-2/branches/JETSPEED-2.1.3/src/webapp/javascript/jetspeed/widget/LayoutEditPane.html?rev=583998&r1=583997&r2=583998&view=diff
==============================================================================
--- portals/jetspeed-2/branches/JETSPEED-2.1.3/src/webapp/javascript/jetspeed/widget/LayoutEditPane.html (original)
+++ portals/jetspeed-2/branches/JETSPEED-2.1.3/src/webapp/javascript/jetspeed/widget/LayoutEditPane.html Thu Oct 11 17:36:12 2007
@@ -17,31 +17,32 @@
 <!--  need to wrap inside a body tag to allow the above license header
       dojo will look for a body tag and use its content -->
 <body>
-<div class="layoutEditPane">
+<div id="${this.widgetId}" class="layoutEditPane">
+
     <div dojoAttachPoint="containerNode" class="container"></div>
 
     <fieldset class="pageEditorPaneContainer" dojoAttachPoint="pageEditContainer">
         <div class="detail">
             <div class="rowContainer">
-                <fieldset class="pageEditorDetailContainer" dojoAttachPoint="pageEditLNContainer">
+                <fieldset class="pageEditorPaneContainer pageEditorDetailContainer" dojoAttachPoint="pageEditLNContainer">
                     <div class="layoutNameContainer">
                         <select class="layoutName" name="layoutNameSelect" dojoAttachPoint="layoutNameSelect" dojoType="Select" autocomplete="false"></select>
                     </div>
                     <div class="buttonContainerLeft">
-                        <button dojoType="Button" dojoAttachPoint="changeLayoutButton" dojoAttachEvent="onClick:changeLayout"><img height="16" src="${this.layoutImagesRoot}button_ok.png">&nbsp;Change Layout</button>
+                        <button dojoType="Button" dojoAttachPoint="changeLayoutButton" dojoAttachEvent="onClick:changeLayout"><img height="16" src="${this.layoutImagesRoot}button_ok.png">&nbsp;${this.labels.changelayout}</button>
                     </div>
                 </fieldset>
                 <div style="float: right; width: 18px">&nbsp;</div>  <!-- allowing room for layout-move image -->
-                <div class="buttonContainerRight">
+                <div class="buttonContainerRight" dojoAttachPoint="buttonGroupRight">
                     <table cellpadding="0" cellspacing="6" border="0">
                     <!-- height on images is currently needed to size the button properly, especially when button is inside a table -->
                     <tr>
-                    <td><button dojoType="Button" dojoAttachEvent="onClick:addPortlet"><img height="16" src="${this.layoutImagesRoot}portlet_add.png">&nbsp;Add Portlet&#133;</button></td>
-                    <td><button dojoType="Button" dojoAttachEvent="onClick:openColumnSizeEditor"><img height="16" src="${this.layoutImagesRoot}column_resize.png">&nbsp;Column Sizes&#133;</button></td>
+                    <td><button dojoType="Button" dojoAttachEvent="onClick:addPortlet"><img height="16" src="${this.layoutImagesRoot}portlet_add.png">&nbsp;${this.labels.addportlet}</button></td>
+                    <td><button dojoType="Button" dojoAttachEvent="onClick:openColumnSizeEditor"><img height="16" src="${this.layoutImagesRoot}column_resize.png">&nbsp;${this.labels.columnsizes}</button></td>
                     </tr>
                     <tr>
-                    <td><button dojoType="Button" dojoAttachEvent="onClick:addLayout"><img height="16" src="${this.layoutImagesRoot}layout_new.png">&nbsp;Add Layout&#133;</button></td>
-                    <td><button dojoType="Button" dojoAttachPoint="deleteLayoutButton" dojoAttachEvent="onClick:deleteLayout"><img height="16" src="${this.layoutImagesRoot}layout_delete.png">&nbsp;Delete Layout&#133;</button><button dojoType="Button" dojoAttachPoint="editModeLayoutMoveButton" dojoAttachEvent="onClick:editModeLayoutMove"><img height="16" src="${this.layoutImagesRoot}edit_mode_layout_move.png">&nbsp;Move Mode</button><button dojoType="Button" dojoAttachPoint="editModeNormalButton" dojoAttachEvent="onClick:editModeNormal"><img height="16" src="${this.layoutImagesRoot}edit_mode_normal.png">&nbsp;Normal Mode</button></td>
+                    <td><button dojoType="Button" dojoAttachEvent="onClick:addLayout"><img height="16" src="${this.layoutImagesRoot}layout_new.png">&nbsp;${this.labels.addlayout}</button></td>
+                    <td><button dojoType="Button" dojoAttachPoint="deleteLayoutButton" dojoAttachEvent="onClick:deleteLayout"><img height="16" src="${this.layoutImagesRoot}layout_delete.png">&nbsp;${this.labels.deletelayout}</button><button dojoType="Button" dojoAttachPoint="editMoveModeButton" dojoAttachEvent="onClick:editMoveModeStart"><img height="16" src="${this.layoutImagesRoot}edit_mode_layout_move.png">&nbsp;${this.labels.movemode}</button><button dojoType="Button" dojoAttachPoint="editMoveModeExitButton" dojoAttachEvent="onClick:editMoveModeExit"><img height="16" src="${this.layoutImagesRoot}edit_mode_normal.png">&nbsp;${this.labels.movemode_exit}</button></td>
                     </tr>
                     </table>
                 </div>
@@ -50,4 +51,4 @@
     </fieldset>
 
 </div>
-</body>
\ No newline at end of file
+</body>

Modified: portals/jetspeed-2/branches/JETSPEED-2.1.3/src/webapp/javascript/jetspeed/widget/LayoutEditPane.js
URL: http://svn.apache.org/viewvc/portals/jetspeed-2/branches/JETSPEED-2.1.3/src/webapp/javascript/jetspeed/widget/LayoutEditPane.js?rev=583998&r1=583997&r2=583998&view=diff
==============================================================================
--- portals/jetspeed-2/branches/JETSPEED-2.1.3/src/webapp/javascript/jetspeed/widget/LayoutEditPane.js (original)
+++ portals/jetspeed-2/branches/JETSPEED-2.1.3/src/webapp/javascript/jetspeed/widget/LayoutEditPane.js Thu Oct 11 17:36:12 2007
@@ -11,7 +11,7 @@
 dojo.require("dojo.html.display");
 jetspeed.widget.LayoutEditPane=function(){
 };
-dojo.widget.defineWidget("jetspeed.widget.LayoutEditPane",dojo.widget.HtmlWidget,{layoutId:null,layoutDefinitions:null,pageEditContainer:null,pageEditLNContainer:null,layoutNameSelect:null,deleteLayoutButton:null,editModeLayoutMoveButton:null,editModeNormalButton:null,layoutMoveContainer:null,isContainer:true,widgetsInTemplate:true,isLayoutPane:true,containingColumn:null,windowPositionStatic:true,postMixInProperties:function(_1,_2,_3){
+dojo.widget.defineWidget("jetspeed.widget.LayoutEditPane",dojo.widget.HtmlWidget,{layoutId:null,layoutDefinitions:null,layoutColumn:null,layoutInfo:null,parentLayoutInfo:null,pageEditContainer:null,pageEditLNContainer:null,layoutNameSelect:null,buttonGroupRight:null,deleteLayoutButton:null,editMoveModeButton:null,editMoveModeExitButton:null,layoutMoveContainer:null,isContainer:true,widgetsInTemplate:true,isLayoutPane:true,drag:null,posStatic:true,moveModeLayoutRelative:"movemode_layout",moveModes:["movemode_layout","movemode_portlet"],postMixInProperties:function(_1,_2,_3){
 jetspeed.widget.LayoutEditPane.superclass.postMixInProperties.apply(this,arguments);
 this.templateCssPath=new dojo.uri.Uri(jetspeed.url.basePortalDesktopUrl()+"/javascript/jetspeed/widget/LayoutEditPane.css");
 this.templatePath=new dojo.uri.Uri(jetspeed.url.basePortalDesktopUrl()+"/javascript/jetspeed/widget/LayoutEditPane.html");
@@ -24,90 +24,176 @@
 }
 return _6;
 },postCreate:function(_7,_8,_9){
-if(!jetspeed.UAie){
+var _a=dojo;
+var _b=_a.html;
+var _c=jetspeed.widget.PageEditor.prototype;
 if(this.pageEditContainer!=null){
-this.pageEditContainer.style.backgroundColor="#d3d3d3";
+_b.addClass(this.pageEditContainer,_c.styleBaseAdd);
 }
 if(this.pageEditLNContainer!=null){
-this.pageEditLNContainer.style.backgroundColor="#eeeeee";
-}
+_b.addClass(this.pageEditLNContainer,_c.styleDetailAdd);
 }
 if(this.layoutNameSelect!=null){
-var _a=this.getCurrentLayout();
-var _b=null;
-if(_a!=null){
-_b=_a.name;
+var _d=this.getCurrentLayout();
+var _e=null;
+if(_d!=null){
+_e=_d.name;
 }
-var _c=[];
+var _f=[];
 if(this.layoutDefinitions){
 for(var i=0;i<this.layoutDefinitions.length;i++){
-var _e=this.layoutDefinitions[i];
-if(_e&&_e.length==2){
-_c.push([_e[0],_e[1]]);
-if(_b==_e[1]){
-this.layoutNameSelect.setAllValues(_e[0],_e[1]);
+var _11=this.layoutDefinitions[i];
+if(_11&&_11.length==2){
+_f.push([_11[0],_11[1]]);
+if(_e==_11[1]){
+this.layoutNameSelect.setAllValues(_11[0],_11[1]);
 }
 }
 }
 }
-this.layoutNameSelect.dataProvider.setData(_c);
+this.layoutNameSelect.dataProvider.setData(_f);
 }
 this.syncButtons();
-this.layoutMoveContainer=dojo.widget.createWidget("jetspeed:LayoutEditPaneMoveHandle",{layoutImagesRoot:this.layoutImagesRoot});
+this.layoutMoveContainer=_a.widget.createWidget("jetspeed:LayoutEditPaneMoveHandle",{layoutImagesRoot:this.layoutImagesRoot});
 this.addChild(this.layoutMoveContainer);
 this.domNode.appendChild(this.layoutMoveContainer.domNode);
-},initializeDrag:function(){
-this.containingColumn=this.getContainingColumn();
-this.drag=new dojo.dnd.Moveable(this,{handle:this.layoutMoveContainer.domNode});
 },changeLayout:function(){
-var _f=new jetspeed.widget.UpdateFragmentContentManager(this.layoutId,this.layoutNameSelect.getValue(),null,this.pageEditorWidget);
-_f.getContent();
+var _12=new jetspeed.widget.UpdateFragmentContentManager(this.layoutId,this.layoutNameSelect.getValue(),null,this.pageEditorWidget);
+_12.getContent();
 },openColumnSizeEditor:function(){
 this.pageEditorWidget.openColumnSizesEditor(this.layoutId);
 },addPortlet:function(){
-var _10=jetspeed.page.getPagePathAndQuery();
-_10=jetspeed.url.addQueryParameter(_10,jetspeed.id.PG_ED_PARAM,"true",true);
-jetspeed.page.addPortletInitiate(this.layoutId,_10.toString());
+var _13=jetspeed.page.getPagePathAndQuery();
+_13=jetspeed.url.addQueryParameter(_13,jetspeed.id.PG_ED_PARAM,"true",true);
+jetspeed.page.addPortletInitiate(this.layoutId,_13.toString());
 },addLayout:function(){
-var _11=this.getCurrentLayout();
-if(_11!=null){
-var _12=new jetspeed.widget.AddLayoutContentManager(this.layoutId,_11.name,this.pageEditorWidget);
-_12.getContent();
+var _14=this.getCurrentLayout();
+if(_14!=null){
+var _15=new jetspeed.widget.AddLayoutContentManager(this.layoutId,_14.name,this.pageEditorWidget);
+_15.getContent();
 }else{
 alert("Cannot add layout (error: null parent layout).");
 }
 },deleteLayout:function(){
 this.pageEditorWidget.deleteLayout(this.layoutId);
-},editModeNormal:function(){
-this.pageEditorWidget.editModeNormal();
-if(this.editModeLayoutMoveButton!=null){
-this.editModeLayoutMoveButton.domNode.style.display="block";
-}
-if(this.editModeNormalButton!=null){
-this.editModeNormalButton.domNode.style.display="none";
-}
-},editModeLayoutMove:function(){
-this.pageEditorWidget.editModeLayoutMove();
-if(this.editModeLayoutMoveButton!=null){
-this.editModeLayoutMoveButton.domNode.style.display="none";
+},editMoveModeExit:function(){
+this.pageEditorWidget.editMoveModeExit();
+if(this.editMoveModeButton!=null){
+this.editMoveModeButton.domNode.style.display="block";
+}
+if(this.editMoveModeExitButton!=null){
+this.editMoveModeExitButton.domNode.style.display="none";
+}
+},editMoveModeStart:function(){
+this.pageEditorWidget.editMoveModeStart();
+if(this.editMoveModeButton!=null){
+this.editMoveModeButton.domNode.style.display="none";
+}
+if(this.editMoveModeExitButton!=null){
+this.editMoveModeExitButton.domNode.style.display="block";
+}
+},_enableMoveMode:function(){
+if(this.layoutMoveContainer&&this.drag){
+this.layoutMoveContainer.domNode.style.display="block";
+}
+},_disableMoveMode:function(){
+if(this.layoutMoveContainer&&this.drag){
+this.layoutMoveContainer.domNode.style.display="none";
 }
-if(this.editModeNormalButton!=null){
-this.editModeNormalButton.domNode.style.display="block";
+},initializeDrag:function(){
+var _16=this.layoutColumn;
+if(_16!=null&&_16.domNode!=null){
+this.dragStartStaticWidth=_16.domNode.style.width;
+this.drag=new dojo.dnd.Moveable(this,{handle:this.layoutMoveContainer.domNode});
 }
-},endDragging:function(){
-if(this.drag==null||this.containingColumn==null||this.containingColumn.domNode==null){
+},startDragging:function(e,_18,_19,_1a){
+var _1b=this.layoutColumn;
+if(_1b!=null){
+var _1c=_1b.domNode;
+if(_1c){
+if(this.buttonGroupRight){
+this.buttonGroupRight.style.display="none";
+}
+var _1d=true;
+_18.beforeDragColRowInfo=_1a.page.getPortletCurColRow(_1c);
+_18.node=_1c;
+_18.mover=new _19.dnd.Mover(this,_1c,_1b,_18,e,_1d,_19,_1a);
+}
+}
+},dragChangeToAbsolute:function(_1e,_1f,_20,_21,_22){
+var _23=_21.getMarginBox(_1f,null,_22);
+var _24=400-_20.w;
+if(_24<0){
+_20.l=_20.l+(_24*-1);
+_20.w=400;
+_21.setMarginBox(_1f,_20.l,null,_20.w,null,null,_22);
+}
+if(_22.UAie){
+var _25=this.pageEditorWidget.bgIframe.iframe;
+this.domNode.appendChild(_25);
+_25.style.display="block";
+_21.setMarginBox(_25,null,null,null,_20.h,null,_22);
+}
+},endDragging:function(_26){
+var _27=jetspeed;
+var _28=dojo;
+var _29=this.layoutColumn;
+if(this.drag==null||_29==null||_29.domNode==null){
 return;
 }
-var _13=this.drag.beforeDragColumnRowInfo;
-if(_13!=null){
-var _14=jetspeed.page.getPortletCurColRow(this.containingColumn.domNode);
-if(_14!=null&&(_14.row!=_13.row||_14.column!=_13.column||_14.layout!=_13.layout)){
+var _2a=_29.domNode;
+_2a.style.position="static";
+_2a.style.width=this.dragStartStaticWidth;
+_2a.style.left="auto";
+_2a.style.top="auto";
+if(this.buttonGroupRight){
+this.buttonGroupRight.style.display="block";
+}
+if(_27.UAie){
+this.pageEditorWidget.bgIframe.iframe.style.display="none";
+}
+var _2b=this.drag.beforeDragColRowInfo;
+var _2c=_27.page.getPortletCurColRow(_2a);
+if(_2b!=null&&_2c!=null){
+var ind=_27.debugindent;
+if(_2c!=null&&(_2c.row!=_2b.row||_2c.column!=_2b.column||_2c.layout!=_2b.layout)){
+var _2e=new _27.widget.MoveLayoutContentManager(this.layoutId,_2c.layout,_2c.column,_2c.row,this.pageEditorWidget);
+_2e.getContent();
 }
 }
-},getContainingColumn:function(){
-return jetspeed.page.getColWithNode(this.domNode);
+},getLayoutColumn:function(){
+return this.layoutColumn;
 },getPageColumnIndex:function(){
-return jetspeed.page.getColIndexForNode(this.domNode);
+if(this.layoutColumn){
+var _2f=jetspeed.page.getColWithNode(this.layoutColumn.domNode);
+if(_2f!=null){
+return _2f.getPageColumnIndex();
+}
+}
+return null;
+},_getLayoutInfoMoveable:function(){
+return this.layoutInfo;
+},_getWindowMarginBox:function(_30,_31){
+if(this.layoutColumn){
+var _32=this.parentLayoutInfo;
+if(_31.UAope&&_32==null){
+var _33=_31.page.layoutInfo;
+var _34=_31.page.getColIndexForNode(this.layoutColumn.domNode);
+if(_34!=null){
+var _35=_31.page.columns[_34];
+if(_35.layoutHeader){
+_32=_33.columnLayoutHeader;
+}else{
+_32=_33.column;
+}
+}else{
+_32=_33.columns;
+}
+this.parentLayoutInfo=_32;
+}
+return _31.ui.getMarginBox(this.layoutColumn.domNode,_30,_32,_31);
+}
+return null;
 },editModeRedisplay:function(){
 this.show();
 this.syncButtons();
@@ -116,20 +202,21 @@
 if(this.deleteLayoutButton!=null){
 this.deleteLayoutButton.domNode.style.display="none";
 }
-if(this.editModeLayoutMoveButton!=null){
-this.editModeLayoutMoveButton.domNode.style.display="block";
+if(this.editMoveModeButton!=null){
+this.editMoveModeButton.domNode.style.display="block";
 }
-if(this.editModeNormalButton!=null){
-this.editModeNormalButton.domNode.style.display="none";
+if(this.editMoveModeExitButton!=null){
+this.editMoveModeExitButton.domNode.style.display="none";
 }
 }else{
-if(this.editModeLayoutMoveButton!=null){
-this.editModeLayoutMoveButton.domNode.style.display="none";
+if(this.editMoveModeButton!=null){
+this.editMoveModeButton.domNode.style.display="none";
 }
-if(this.editModeNormalButton!=null){
-this.editModeNormalButton.domNode.style.display="none";
+if(this.editMoveModeExitButton!=null){
+this.editMoveModeExitButton.domNode.style.display="none";
 }
 }
+},onBrowserWindowResize:function(){
 }});
 dojo.widget.defineWidget("jetspeed.widget.LayoutEditPaneMoveHandle",dojo.widget.HtmlWidget,{templateString:"<span class=\"layoutMoveContainer\"><img src=\"${this.layoutImagesRoot}layout_move.png\"></span>"});
 

Modified: portals/jetspeed-2/branches/JETSPEED-2.1.3/src/webapp/javascript/jetspeed/widget/LayoutEditPane.src.js
URL: http://svn.apache.org/viewvc/portals/jetspeed-2/branches/JETSPEED-2.1.3/src/webapp/javascript/jetspeed/widget/LayoutEditPane.src.js?rev=583998&r1=583997&r2=583998&view=diff
==============================================================================
--- portals/jetspeed-2/branches/JETSPEED-2.1.3/src/webapp/javascript/jetspeed/widget/LayoutEditPane.src.js (original)
+++ portals/jetspeed-2/branches/JETSPEED-2.1.3/src/webapp/javascript/jetspeed/widget/LayoutEditPane.src.js Thu Oct 11 17:36:12 2007
@@ -43,23 +43,33 @@
         layoutId: null,
         layoutDefinitions: null,
 
+        layoutColumn: null,
+        layoutInfo: null,
+        parentLayoutInfo: null,
+
         // template parameters
         pageEditContainer: null,
         pageEditLNContainer: null,
         layoutNameSelect: null,
+        buttonGroupRight: null,
         deleteLayoutButton: null,
-        editModeLayoutMoveButton: null,
-        editModeNormalButton: null,
+        editMoveModeButton: null,
+        editMoveModeExitButton: null,
         layoutMoveContainer: null,
-        
+
         // fields
 		isContainer: true,
         widgetsInTemplate: true,
         isLayoutPane: true,
 
         // drag variables
-        containingColumn: null,
-        windowPositionStatic: true,
+        drag: null,
+        posStatic: true,
+
+        // move modes
+        moveModeLayoutRelative: "movemode_layout",
+        moveModes: [ "movemode_layout", "movemode_portlet" ],
+
 
         // protocol - dojo.widget.Widget create
 
@@ -88,13 +98,14 @@
 
         postCreate: function( args, fragment, parent )
         {
-            if ( ! jetspeed.UAie )
-            {   /* in IE6, if fieldset background color is set the fieldset will not be rendered nicely (with rounded borders) */
-                if ( this.pageEditContainer != null )
-                    this.pageEditContainer.style.backgroundColor = "#d3d3d3";
-                if ( this.pageEditLNContainer != null )
-                    this.pageEditLNContainer.style.backgroundColor = "#eeeeee";
-            }
+            var djObj = dojo;
+            var djH = djObj.html;
+
+            var pageEditorProto = jetspeed.widget.PageEditor.prototype;
+            if ( this.pageEditContainer != null )
+                djH.addClass( this.pageEditContainer, pageEditorProto.styleBaseAdd );
+            if ( this.pageEditLNContainer != null )
+                djH.addClass( this.pageEditLNContainer, pageEditorProto.styleDetailAdd );
 
             if ( this.layoutNameSelect != null )
             {
@@ -124,7 +135,7 @@
             }
             this.syncButtons();
             
-            this.layoutMoveContainer = dojo.widget.createWidget( "jetspeed:LayoutEditPaneMoveHandle",
+            this.layoutMoveContainer = djObj.widget.createWidget( "jetspeed:LayoutEditPaneMoveHandle",
 				{
 					layoutImagesRoot: this.layoutImagesRoot
 				});
@@ -132,12 +143,6 @@
 			this.domNode.appendChild( this.layoutMoveContainer.domNode );
         },
 
-        initializeDrag: function()
-        {
-            this.containingColumn = this.getContainingColumn();
-            this.drag = new dojo.dnd.Moveable( this, {handle: this.layoutMoveContainer.domNode});
-        },
-
         // methods
 
         changeLayout: function()
@@ -172,50 +177,171 @@
         {
             this.pageEditorWidget.deleteLayout( this.layoutId );
         },
-        editModeNormal: function()
+        editMoveModeExit: function()
+        {
+            this.pageEditorWidget.editMoveModeExit();
+            if ( this.editMoveModeButton != null )
+                this.editMoveModeButton.domNode.style.display = "block";
+            if ( this.editMoveModeExitButton != null )
+                this.editMoveModeExitButton.domNode.style.display = "none";
+        },
+        editMoveModeStart: function()
+        {
+            this.pageEditorWidget.editMoveModeStart();
+            if ( this.editMoveModeButton != null )
+                this.editMoveModeButton.domNode.style.display = "none";
+            if ( this.editMoveModeExitButton != null )
+                this.editMoveModeExitButton.domNode.style.display = "block";
+        },
+
+        _enableMoveMode: function()
+        {
+            if ( this.layoutMoveContainer && this.drag )
+            {
+                this.layoutMoveContainer.domNode.style.display = "block";
+            }
+        },
+        _disableMoveMode: function()
+        {
+            if ( this.layoutMoveContainer && this.drag )
+            {
+                this.layoutMoveContainer.domNode.style.display = "none";
+            }
+        },
+
+        initializeDrag: function()
+        {
+            var layoutCol = this.layoutColumn;
+            if ( layoutCol != null && layoutCol.domNode != null )
+            {
+                this.dragStartStaticWidth = layoutCol.domNode.style.width;
+                this.drag = new dojo.dnd.Moveable( this, {handle: this.layoutMoveContainer.domNode });
+            }
+        },
+        
+        startDragging: function( e, moveableObj, djObj, jsObj )
         {
-            this.pageEditorWidget.editModeNormal();
-            if ( this.editModeLayoutMoveButton != null )
-                this.editModeLayoutMoveButton.domNode.style.display = "block";
-            if ( this.editModeNormalButton != null )
-                this.editModeNormalButton.domNode.style.display = "none";
+            var dragLayoutColumn = this.layoutColumn;
+            if ( dragLayoutColumn != null )
+            {
+                var dragNode = dragLayoutColumn.domNode;
+                if ( dragNode )
+                {
+                    if ( this.buttonGroupRight )
+                        this.buttonGroupRight.style.display = "none";
+                    var notifyOnAbsolute = true;
+                    moveableObj.beforeDragColRowInfo = jsObj.page.getPortletCurColRow( dragNode );
+                    moveableObj.node = dragNode;
+		            moveableObj.mover = new djObj.dnd.Mover( this, dragNode, dragLayoutColumn, moveableObj, e, notifyOnAbsolute, djObj, jsObj );
+                }
+            }
         },
-        editModeLayoutMove: function()
+
+        dragChangeToAbsolute: function( moverObj, layoutColNode, mbLayoutColNode, djObj, jsObj )
         {
-            this.pageEditorWidget.editModeLayoutMove();
-            if ( this.editModeLayoutMoveButton != null )
-                this.editModeLayoutMoveButton.domNode.style.display = "none";
-            if ( this.editModeNormalButton != null )
-                this.editModeNormalButton.domNode.style.display = "block";
+            var mbLayoutColNodeFresh = djObj.getMarginBox( layoutColNode, null, jsObj );
+            //dojo.debug( "dragChangeToAbsolute - passed-mb=" + jsObj.printobj( mbLayoutColNode ) + "  fresh-mb=" + jsObj.printobj( mbLayoutColNodeFresh ) );
+            var reduceWidth = 400 - mbLayoutColNode.w;
+            if ( reduceWidth < 0 )
+            {
+                mbLayoutColNode.l = mbLayoutColNode.l + ( reduceWidth * -1 );  // ( mbLayoutColNode.w + reduceWidth );
+                mbLayoutColNode.w = 400;
+                djObj.setMarginBox( layoutColNode, mbLayoutColNode.l, null, mbLayoutColNode.w, null, null, jsObj );
+            }
+            
+            if ( jsObj.UAie )
+            {
+                var bgIframeNode = this.pageEditorWidget.bgIframe.iframe;
+                this.domNode.appendChild( bgIframeNode );
+                bgIframeNode.style.display = "block";
+                djObj.setMarginBox( bgIframeNode, null, null, null, mbLayoutColNode.h, null, jsObj );
+                //djObj.debug( "layout bgIframe mb: " + jsObj.printobj( djObj.getMarginBox( bgIframeNode, null, jsObj ) ) );
+            }
         },
 
-        endDragging: function()
+        endDragging: function( posObj )
         {
-            if ( this.drag == null || this.containingColumn == null || this.containingColumn.domNode == null ) return;
-            var beforeDragColumnRowInfo = this.drag.beforeDragColumnRowInfo;
-            //dojo.debug( "layout (" + this.layoutId + " / " + this.widgetId + ") endDragging (a) : before " + jetspeed.printobj( beforeDragColumnRowInfo ) );
-            if ( beforeDragColumnRowInfo != null )
+            var jsObj = jetspeed;
+            var djObj = dojo;
+            var layoutCol = this.layoutColumn;
+            if ( this.drag == null || layoutCol == null || layoutCol.domNode == null ) return;
+            var dNode = layoutCol.domNode;
+            dNode.style.position = "static";
+            dNode.style.width = this.dragStartStaticWidth;
+            dNode.style.left = "auto";
+            dNode.style.top = "auto";
+
+            if ( this.buttonGroupRight )
+                this.buttonGroupRight.style.display = "block";
+
+            if ( jsObj.UAie )
+                this.pageEditorWidget.bgIframe.iframe.style.display = "none";
+
+            var beforeDragColRowInfo = this.drag.beforeDragColRowInfo;
+            var afterDragColRowInfo = jsObj.page.getPortletCurColRow( dNode );
+            if ( beforeDragColRowInfo != null && afterDragColRowInfo != null )
             {
-                var afterDragColumnRowInfo = jetspeed.page.getPortletCurColRow( this.containingColumn.domNode );
-                //dojo.debug( "layout (" + this.layoutId + ") endDragging (b) : after " + jetspeed.printobj( afterDragColumnRowInfo ) );
-                if ( afterDragColumnRowInfo != null && ( afterDragColumnRowInfo.row != beforeDragColumnRowInfo.row || afterDragColumnRowInfo.column != beforeDragColumnRowInfo.column || afterDragColumnRowInfo.layout != beforeDragColumnRowInfo.layout ) )
+                var ind = jsObj.debugindent;
+                //djObj.hostenv.println( "move-layout[" + this.layoutId + " / " + dNode.id + "]" );
+                //djObj.hostenv.println( ind + "before (col=" + beforeDragColRowInfo.column + " row=" + beforeDragColRowInfo.row + " layout=" + beforeDragColRowInfo.layout + ")" );
+                //djObj.hostenv.println( ind + "before-" + jetspeed.debugColumn( beforeDragColRowInfo.columnObj, true ) );
+                //djObj.hostenv.println( ind + "after (col=" + afterDragColRowInfo.column + " row=" + afterDragColRowInfo.row + " layout=" + afterDragColRowInfo.layout + ")" );
+                //djObj.hostenv.println( ind + "after-" + jetspeed.debugColumn( afterDragColRowInfo.columnObj, true ) );
+
+                if ( afterDragColRowInfo != null && ( afterDragColRowInfo.row != beforeDragColRowInfo.row || afterDragColRowInfo.column != beforeDragColRowInfo.column || afterDragColRowInfo.layout != beforeDragColRowInfo.layout ) )
                 {
-                    //dojo.debug( "layout (" + this.layoutId + ") endDragging (c)" );
-                    //var moveLayoutContentManager = new jetspeed.widget.MoveLayoutContentManager( this.layoutId, afterDragColumnRowInfo.layout, afterDragColumnRowInfo.column, afterDragColumnRowInfo.row, this.pageEditorWidget );
-                    //moveLayoutContentManager.getContent();
+                    var moveLayoutContentManager = new jsObj.widget.MoveLayoutContentManager( this.layoutId, afterDragColRowInfo.layout, afterDragColRowInfo.column, afterDragColRowInfo.row, this.pageEditorWidget );
+                    moveLayoutContentManager.getContent();
                 }
             }
         },
 
-        getContainingColumn: function()
+        getLayoutColumn: function()
         {
-            return jetspeed.page.getColWithNode( this.domNode );
+            return this.layoutColumn;
         },
         getPageColumnIndex: function()
         {
-            return jetspeed.page.getColIndexForNode( this.domNode );
+            if ( this.layoutColumn )
+            {
+                var parentColObj = jetspeed.page.getColWithNode( this.layoutColumn.domNode );
+                if ( parentColObj != null )
+                    return parentColObj.getPageColumnIndex();
+            }
+            return null;
         },
-        
+        _getLayoutInfoMoveable: function()
+        {
+            return this.layoutInfo;
+        },
+        _getWindowMarginBox: function( layoutColumnLayoutInfo, jsObj )
+        {
+            if ( this.layoutColumn )
+            {
+                var parentLayoutInfo = this.parentLayoutInfo;
+                if ( jsObj.UAope && parentLayoutInfo == null )  // needs parentNode layout-info 
+                {
+                    var pageLayoutInfo = jsObj.page.layoutInfo;
+                    var parentColIndex = jsObj.page.getColIndexForNode( this.layoutColumn.domNode );
+                    if ( parentColIndex != null )
+                    {
+                        var parentCol = jsObj.page.columns[parentColIndex];
+                        if ( parentCol.layoutHeader )
+                            parentLayoutInfo = pageLayoutInfo.columnLayoutHeader;
+                        else
+                            parentLayoutInfo = pageLayoutInfo.column;
+                    }
+                    else
+                    {
+                        parentLayoutInfo = pageLayoutInfo.columns;
+                    }
+                    this.parentLayoutInfo = parentLayoutInfo;
+                }
+                return jsObj.ui.getMarginBox( this.layoutColumn.domNode, layoutColumnLayoutInfo, parentLayoutInfo, jsObj );
+            }
+            return null;
+        },
+
         editModeRedisplay: function()
         {
             this.show();
@@ -227,18 +353,23 @@
             {
                 if ( this.deleteLayoutButton != null )
                     this.deleteLayoutButton.domNode.style.display = "none";
-                if ( this.editModeLayoutMoveButton != null )
-                    this.editModeLayoutMoveButton.domNode.style.display = "block";
-                if ( this.editModeNormalButton != null )
-                    this.editModeNormalButton.domNode.style.display = "none";
+                if ( this.editMoveModeButton != null )
+                    this.editMoveModeButton.domNode.style.display = "block";
+                if ( this.editMoveModeExitButton != null )
+                    this.editMoveModeExitButton.domNode.style.display = "none";
             }
             else
             {
-                if ( this.editModeLayoutMoveButton != null )
-                    this.editModeLayoutMoveButton.domNode.style.display = "none";
-                if ( this.editModeNormalButton != null )
-                    this.editModeNormalButton.domNode.style.display = "none";
+                if ( this.editMoveModeButton != null )
+                    this.editMoveModeButton.domNode.style.display = "none";
+                if ( this.editMoveModeExitButton != null )
+                    this.editMoveModeExitButton.domNode.style.display = "none";
             }
+        },
+
+        onBrowserWindowResize: function()
+        {   // called after ie6 resize window
+            // nothing to do here
         }
 	}
 );

Modified: portals/jetspeed-2/branches/JETSPEED-2.1.3/src/webapp/javascript/jetspeed/widget/PageEditPane.css
URL: http://svn.apache.org/viewvc/portals/jetspeed-2/branches/JETSPEED-2.1.3/src/webapp/javascript/jetspeed/widget/PageEditPane.css?rev=583998&r1=583997&r2=583998&view=diff
==============================================================================
--- portals/jetspeed-2/branches/JETSPEED-2.1.3/src/webapp/javascript/jetspeed/widget/PageEditPane.css (original)
+++ portals/jetspeed-2/branches/JETSPEED-2.1.3/src/webapp/javascript/jetspeed/widget/PageEditPane.css Thu Oct 11 17:36:12 2007
@@ -52,8 +52,10 @@
 
 .dojoDialog .deletePageDialog { background: #eee; width: 20em; border: 1px solid #999; padding : 4px; -moz-border-radius: 5px; }
 .dojoDialog .deletePageDialog h2 { margin-top: 0; padding-top: 0; }
-.dojoDialog .deletePageDialog p { clear: both; }
-.dojoDialog .deletePageDialog .dojoButton { float: right; margin-right: 5px }
+.dojoDialog .deletePageDialog p {  }
+.dojoDialog .deletePageDialog .dojoButton { margin-right: 5px }
+.dojoDialog .dialogBottom { position: relative; width: 100%; height: 30px; margin: 3px }
+.dojoDialog .dialogButtonContainerRight { position: absolute; bottom: 2px; left: 2px; }
 
 .dojoDialog .createPageDialog { background: #eee; width: 20em; border: 1px solid #999; padding : 4px; -moz-border-radius: 5px; }
 .dojoDialog .createPageDialog h2 { margin-top: 0; padding-top: 0; }

Modified: portals/jetspeed-2/branches/JETSPEED-2.1.3/src/webapp/javascript/jetspeed/widget/PageEditPane.html
URL: http://svn.apache.org/viewvc/portals/jetspeed-2/branches/JETSPEED-2.1.3/src/webapp/javascript/jetspeed/widget/PageEditPane.html?rev=583998&r1=583997&r2=583998&view=diff
==============================================================================
--- portals/jetspeed-2/branches/JETSPEED-2.1.3/src/webapp/javascript/jetspeed/widget/PageEditPane.html (original)
+++ portals/jetspeed-2/branches/JETSPEED-2.1.3/src/webapp/javascript/jetspeed/widget/PageEditPane.html Thu Oct 11 17:36:12 2007
@@ -18,32 +18,33 @@
       dojo will look for a body tag and use its content -->
 <body>
 <div class="pageEditPane">
+
     <div dojoAttachPoint="containerNode" class="container"></div>
 
     <fieldset class="pageEditorPaneContainer" dojoAttachPoint="pageEditContainer">
         <div class="detail">
-            <div><img src="${this.layoutImagesRoot}customizer.png">&nbsp;<span class="pageEditorName">Jetspeed Customizer</span></div>
+            <div><img src="${this.layoutImagesRoot}customizer.png">&nbsp;<span class="pageEditorName">${this.labels.title}</span></div>
             <div class="rowContainer">
-               <fieldset class="pageEditorDetailContainer" dojoAttachPoint="pageEditLDContainer">
+               <fieldset class="pageEditorPaneContainer pageEditorDetailContainer" dojoAttachPoint="pageEditLDContainer">
                    <div class="layoutDecoratorContainer">
                        <select class="layoutDecorator" name="layoutDecoratorSelect" dojoAttachPoint="layoutDecoratorSelect" dojoType="Select" autocomplete="false"></select>
                    </div>
-                   <button dojoType="Button" dojoAttachPoint="changeLayoutDecoratorButton" dojoAttachEvent="onClick:changeLayoutDecorator"><img height="16" src="${this.layoutImagesRoot}button_ok.png">&nbsp;Change Layout Theme</button>
+                   <button dojoType="Button" dojoAttachPoint="changeLayoutDecoratorButton" dojoAttachEvent="onClick:changeLayoutDecorator"><img height="16" src="${this.layoutImagesRoot}button_ok.png">&nbsp;${this.labels.changelayouttheme}</button>
                </fieldset>
-               <fieldset class="pageEditorDetailContainer" dojoAttachPoint="pageEditPDContainer">
+               <fieldset class="pageEditorPaneContainer pageEditorDetailContainer" dojoAttachPoint="pageEditPDContainer">
                    <div class="portletDecoratorContainer">
                        <select class="portletDecorator" name="portletDecoratorSelect" dojoAttachPoint="portletDecoratorSelect" dojoType="Select" autocomplete="false"></select>
                    </div>
-                   <button dojoType="Button" dojoAttachPoint="changePortletDecoratorButton" dojoAttachEvent="onClick:changePortletDecorator"><img height="16" src="${this.layoutImagesRoot}button_ok.png">&nbsp;Change Portlet Theme</button>
+                   <button dojoType="Button" dojoAttachPoint="changePortletDecoratorButton" dojoAttachEvent="onClick:changePortletDecorator"><img height="16" src="${this.layoutImagesRoot}button_ok.png">&nbsp;${this.labels.changeportlettheme}</button>
                </fieldset>
                <div class="buttonContainerRight">
                    <table cellpadding="0" cellspacing="6" border="0">
                    <!-- height on images is currently needed to size the button properly, especially when button is inside a table -->
                    <tr align="right">
-                   <td><button dojoType="Button" dojoAttachEvent="onClick:createPage"><img height="16" src="${this.layoutImagesRoot}page_new.png">&nbsp;Create New Page&#133;</button></td>
+                   <td><button dojoType="Button" dojoAttachEvent="onClick:createPage"><img height="16" src="${this.layoutImagesRoot}page_new.png">&nbsp;${this.labels.newpage}</button></td>
                    </tr>
                    <tr align="right">
-                   <td><button dojoType="Button" dojoAttachEvent="onClick:deletePage"><img height="16" src="${this.layoutImagesRoot}page_delete.png">&nbsp;Delete Page&#133;</button></td>
+                   <td><button dojoType="Button" dojoAttachEvent="onClick:deletePage"><img height="16" src="${this.layoutImagesRoot}page_delete.png">&nbsp;${this.labels.deletepage}</button></td>
                    </tr>
                    </table>
                </div>
@@ -54,9 +55,15 @@
 	<div dojoAttachPoint="deletePageDialog">
 		<div class="container" dojoAttachPoint="deletePageDialogBg">
 			<div class="deletePageDialog" dojoAttachPoint="deletePageDialogFg">
-				<h2>Are you sure you want to delete this page?</h2>
-				<button dojoType="Button" id="deletePageYes" dojoAttachEvent="onClick:deletePageConfirmed">Yes</button>
-				<button dojoType="Button" id="deletePageNo" dojoAttachPoint="deletePageCancel">No</button>
+				<h2>${this.dialogLabels.deletepage}</h2>
+                <div class="dialogBottom">
+                    <div class="dialogButtonContainerRight">
+                        <table><tr>
+				        <td><button dojoType="Button" id="deletePageYes" dojoAttachEvent="onClick:deletePageConfirmed">${this.dialogLabels.yes}</button></td>
+				        <td><button dojoType="Button" id="deletePageNo" dojoAttachPoint="deletePageCancel">${this.dialogLabels.no}</button></td>
+                        </tr></table>
+                    </div>
+                </div>
 				<p></p>
 			</div>
 		</div>
@@ -65,25 +72,25 @@
     <div dojoAttachPoint="createPageDialog">
 		<div class="container" dojoAttachPoint="createPageDialogBg">
 			<div class="createPageDialog" dojoAttachPoint="createPageDialogFg">
-				<h2>Create New Page</h2>
+				<h2>${this.dialogLabels.newpage}</h2>
                 <div dojoAttachPoint="createPageNameField" class="createPageField">
-                    <div>Name</div>
+                    <div>${this.dialogLabels.newpage_name}</div>
                     <input dojoType="Textbox" dojoAttachPoint="createPageNameTextbox" maxlength="30">
                 </div>
                 <div dojoAttachPoint="createPageTitleField" class="createPageField">
-                    <div>Title</div>
+                    <div>${this.dialogLabels.newpage_title}</div>
                     <input dojoType="Textbox" dojoAttachPoint="createPageTitleTextbox" maxlength="30">
                 </div>
                 <div dojoAttachPoint="createPageShortTitleField" class="createPageField">
-                    <div>Short Title</div>
+                    <div>${this.dialogLabels.newpage_titleshort}</div>
                     <input dojoType="Textbox" dojoAttachPoint="createPageShortTitleTextbox" maxlength="30">
                 </div>
-				<button dojoType="Button" id="createPageYes" dojoAttachEvent="onClick:createPageConfirmed">OK</button>
-				<button dojoType="Button" id="createPageNo" dojoAttachPoint="createPageCancel">Cancel</button>
+				<button dojoType="Button" id="createPageYes" dojoAttachEvent="onClick:createPageConfirmed">${this.dialogLabels.ok}</button>
+				<button dojoType="Button" id="createPageNo" dojoAttachPoint="createPageCancel">${this.dialogLabels.cancel}</button>
 				<p></p>
 			</div>
 		</div>
 	</div>
 
 </div>
-</body>
\ No newline at end of file
+</body>

Modified: portals/jetspeed-2/branches/JETSPEED-2.1.3/src/webapp/javascript/jetspeed/widget/PageEditPane.js
URL: http://svn.apache.org/viewvc/portals/jetspeed-2/branches/JETSPEED-2.1.3/src/webapp/javascript/jetspeed/widget/PageEditPane.js?rev=583998&r1=583997&r2=583998&view=diff
==============================================================================
--- portals/jetspeed-2/branches/JETSPEED-2.1.3/src/webapp/javascript/jetspeed/widget/PageEditPane.js (original)
+++ portals/jetspeed-2/branches/JETSPEED-2.1.3/src/webapp/javascript/jetspeed/widget/PageEditPane.js Thu Oct 11 17:36:12 2007
@@ -42,71 +42,83 @@
 }
 jetspeed.widget.PageEditPane.superclass.destroy.apply(this,arguments);
 },postCreate:function(_b,_c,_d){
-jetspeed.widget.PageEditPane.superclass.postCreate.apply(this,arguments);
-if(!jetspeed.UAie){
+var _e=jetspeed;
+var _f=dojo.html;
+_e.widget.PageEditPane.superclass.postCreate.apply(this,arguments);
+var _10=_e.widget.PageEditor.prototype;
 if(this.pageEditContainer!=null){
-this.pageEditContainer.style.backgroundColor="#d3d3d3";
+_f.addClass(this.pageEditContainer,_10.styleBaseAdd);
 }
 if(this.pageEditLDContainer!=null){
-this.pageEditLDContainer.style.backgroundColor="#eeeeee";
+_f.addClass(this.pageEditLDContainer,_10.styleDetailAdd);
 }
 if(this.pageEditPDContainer!=null){
-this.pageEditPDContainer.style.backgroundColor="#eeeeee";
-}
+_f.addClass(this.pageEditPDContainer,_10.styleDetailAdd);
 }
 if(this.layoutDecoratorSelect!=null){
-var _e=jetspeed.page.layoutDecorator;
-var _f=[];
+var _11=_e.page.layoutDecorator;
+var _12=[];
 if(this.layoutDecoratorDefinitions){
 for(var i=0;i<this.layoutDecoratorDefinitions.length;i++){
-var _11=this.layoutDecoratorDefinitions[i];
-if(_11&&_11.length==2){
-_f.push([_11[0],_11[1]]);
-if(_e==_11[1]){
-this.layoutDecoratorSelect.setAllValues(_11[0],_11[1]);
+var _14=this.layoutDecoratorDefinitions[i];
+if(_14&&_14.length==2){
+_12.push([_14[0],_14[1]]);
+if(_11==_14[1]){
+this.layoutDecoratorSelect.setAllValues(_14[0],_14[1]);
 }
 }
 }
 }
-this.layoutDecoratorSelect.dataProvider.setData(_f);
+this.layoutDecoratorSelect.dataProvider.setData(_12);
 }
 if(this.portletDecoratorSelect!=null){
-var _12=jetspeed.page.portletDecorator;
-var _13=[];
+var _15=_e.page.portletDecorator;
+var _16=[];
 if(this.portletDecoratorDefinitions){
 for(var i=0;i<this.portletDecoratorDefinitions.length;i++){
-var _14=this.portletDecoratorDefinitions[i];
-if(_14&&_14.length==2){
-_13.push([_14[0],_14[1]]);
-if(_12==_14[1]){
-this.portletDecoratorSelect.setAllValues(_14[0],_14[1]);
+var _17=this.portletDecoratorDefinitions[i];
+if(_17&&_17.length==2){
+_16.push([_17[0],_17[1]]);
+if(_15==_17[1]){
+this.portletDecoratorSelect.setAllValues(_17[0],_17[1]);
 }
 }
 }
 }
-this.portletDecoratorSelect.dataProvider.setData(_13);
+this.portletDecoratorSelect.dataProvider.setData(_16);
 }
 },deletePage:function(){
-this.deletePageDialog.show();
+this.pageEditorWidget._openDialog(this.deletePageDialog);
 },deletePageConfirmed:function(){
-var _15=new jetspeed.widget.RemovePageContentManager(this.pageEditorWidget);
-_15.getContent();
+var _18=new jetspeed.widget.RemovePageContentManager(this.pageEditorWidget);
+_18.getContent();
 },createPage:function(){
-this.createPageDialog.show();
-},createPageConfirmed:function(_16,_17,_18){
-if(_16!=null&&_16.length>0){
-var _19=jetspeed.page.getPageDirectory(true)+_16;
-var _1a=jetspeed.page.getPageDirectory()+_16;
-var _1b=new jetspeed.widget.AddPageContentManager(_19,_1a,_16,null,_17,_18,this.pageEditorWidget);
-_1b.getContent();
+this.pageEditorWidget._openDialog(this.createPageDialog);
+},createPageConfirmed:function(_19,_1a,_1b){
+if(_19!=null&&_19.length>0){
+var _1c=jetspeed.page.getPageDirectory(true)+_19;
+var _1d=jetspeed.page.getPageDirectory()+_19;
+var _1e=new jetspeed.widget.AddPageContentManager(_1c,_1d,_19,null,_1a,_1b,this.pageEditorWidget);
+_1e.getContent();
 }
 },changeLayoutDecorator:function(){
-var _1c=new jetspeed.widget.UpdatePageInfoContentManager(this.layoutDecoratorSelect.getValue(),null,this.pageEditorWidget);
-_1c.getContent();
+var _1f=new jetspeed.widget.UpdatePageInfoContentManager(this.layoutDecoratorSelect.getValue(),null,this.pageEditorWidget);
+_1f.getContent();
 },changePortletDecorator:function(){
-var _1d=new jetspeed.widget.UpdatePageInfoContentManager(null,this.portletDecoratorSelect.getValue(),this.pageEditorWidget);
-_1d.getContent();
+var _20=new jetspeed.widget.UpdatePageInfoContentManager(null,this.portletDecoratorSelect.getValue(),this.pageEditorWidget);
+_20.getContent();
 },editModeRedisplay:function(){
 this.show();
+},onBrowserWindowResize:function(){
+var _21=this.deletePageDialog;
+var _22=this.createPageDialog;
+if(_21&&_21.isShowing()){
+_21.domNode.style.display="none";
+_21.domNode.style.display="block";
+}
+if(_22&&_22.isShowing()){
+_22.domNode.style.display="none";
+_22.domNode.style.display="block";
+}
 }});
 

Modified: portals/jetspeed-2/branches/JETSPEED-2.1.3/src/webapp/javascript/jetspeed/widget/PageEditPane.src.js
URL: http://svn.apache.org/viewvc/portals/jetspeed-2/branches/JETSPEED-2.1.3/src/webapp/javascript/jetspeed/widget/PageEditPane.src.js?rev=583998&r1=583997&r2=583998&view=diff
==============================================================================
--- portals/jetspeed-2/branches/JETSPEED-2.1.3/src/webapp/javascript/jetspeed/widget/PageEditPane.src.js (original)
+++ portals/jetspeed-2/branches/JETSPEED-2.1.3/src/webapp/javascript/jetspeed/widget/PageEditPane.src.js Thu Oct 11 17:36:12 2007
@@ -103,21 +103,21 @@
 
         postCreate: function( args, fragment, parent )
         {
-            jetspeed.widget.PageEditPane.superclass.postCreate.apply( this, arguments );
-
-            if ( ! jetspeed.UAie )
-            {   /* in IE6, if fieldset background color is set the fieldset will not be rendered nicely (with rounded borders) */
-                if ( this.pageEditContainer != null )
-                    this.pageEditContainer.style.backgroundColor = "#d3d3d3";
-                if ( this.pageEditLDContainer != null )
-                    this.pageEditLDContainer.style.backgroundColor = "#eeeeee";
-                if ( this.pageEditPDContainer != null )
-                    this.pageEditPDContainer.style.backgroundColor = "#eeeeee";
-            }
+            var jsObj = jetspeed;
+            var djH = dojo.html;
+            jsObj.widget.PageEditPane.superclass.postCreate.apply( this, arguments );
+            
+            var pageEditorProto = jsObj.widget.PageEditor.prototype;
+            if ( this.pageEditContainer != null )
+                djH.addClass( this.pageEditContainer, pageEditorProto.styleBaseAdd );
+            if ( this.pageEditLDContainer != null )
+                djH.addClass( this.pageEditLDContainer, pageEditorProto.styleDetailAdd );
+            if ( this.pageEditPDContainer != null )
+                djH.addClass( this.pageEditPDContainer, pageEditorProto.styleDetailAdd );
 
             if ( this.layoutDecoratorSelect != null )
             {    
-                var currentLayoutDecorator = jetspeed.page.layoutDecorator;
+                var currentLayoutDecorator = jsObj.page.layoutDecorator;
     
                 var layoutDecoratorData = [];
                 if ( this.layoutDecoratorDefinitions )
@@ -140,7 +140,7 @@
 
             if ( this.portletDecoratorSelect != null )
             {    
-                var currentPortletDecorator = jetspeed.page.portletDecorator;
+                var currentPortletDecorator = jsObj.page.portletDecorator;
     
                 var portletDecoratorData = [];
                 if ( this.portletDecoratorDefinitions )
@@ -167,7 +167,7 @@
 
         deletePage: function()
         {
-            this.deletePageDialog.show();
+            this.pageEditorWidget._openDialog( this.deletePageDialog );
         },
         deletePageConfirmed: function()
         {
@@ -176,7 +176,7 @@
         },
         createPage: function()
         {
-            this.createPageDialog.show();
+            this.pageEditorWidget._openDialog( this.createPageDialog );
         },
         createPageConfirmed: function( pageName, pageTitle, pageShortTitle )
         {
@@ -201,6 +201,21 @@
         editModeRedisplay: function()
         {
             this.show();
+        },
+        onBrowserWindowResize: function()
+        {   // called after ie6 resize window
+            var deletePageDialog = this.deletePageDialog;
+            var createPageDialog = this.createPageDialog;
+            if ( deletePageDialog && deletePageDialog.isShowing() )
+            {
+                deletePageDialog.domNode.style.display = "none";
+                deletePageDialog.domNode.style.display = "block";
+            }
+            if ( createPageDialog && createPageDialog.isShowing() )
+            {
+                createPageDialog.domNode.style.display = "none";
+                createPageDialog.domNode.style.display = "block";
+            }
         }
 	}
 );

Modified: portals/jetspeed-2/branches/JETSPEED-2.1.3/src/webapp/javascript/jetspeed/widget/PageEditor.css
URL: http://svn.apache.org/viewvc/portals/jetspeed-2/branches/JETSPEED-2.1.3/src/webapp/javascript/jetspeed/widget/PageEditor.css?rev=583998&r1=583997&r2=583998&view=diff
==============================================================================
--- portals/jetspeed-2/branches/JETSPEED-2.1.3/src/webapp/javascript/jetspeed/widget/PageEditor.css (original)
+++ portals/jetspeed-2/branches/JETSPEED-2.1.3/src/webapp/javascript/jetspeed/widget/PageEditor.css Thu Oct 11 17:36:12 2007
@@ -36,29 +36,134 @@
 .dojoDialog .columnSizeDialog .columnSizeField .missing { font-size: 8pt; color: red }
 .dojoDialog .columnSizeDialog .columnSizeField .invalid { font-size: 8pt; color: red }
 
+
+
 .pageEditorPaneContainer {
     padding: 0.35em 0.625em 0.75em 0.625em;
+
+    -moz-border-radius: 5px;
+    -moz-border-top-colors: ThreeDLightShadow ThreeDHighlight;
+    -moz-border-right-colors: ThreeDDarkShadow ThreeDShadow;
+    -moz-border-bottom-colors: ThreeDDarkShadow ThreeDShadow;
+    -moz-border-left-colors: ThreeDLightShadow ThreeDHighlight;   
+}
+
+.pageEditorPaneContainerNotIE {
+    background-color: #d3d3d3;
+
+}
+.pageEditorPaneContainerIE {
+    /* background-color: #d3d3d3; */
+    /* if background-color is set, IE6 and IE7 will not render rounded corner border for fieldset node */
+    /*    the reason fieldset is used here is to make it possible to get rounded corners in IE */
+}
+
+.pageEditorDetailContainer {
+    float: left;
+
+    margin-right: 10px;
+    margin-bottom: 10px;
+}
+
+.pageEditorDetailContainerNotIE {
+    background-color: #eeeeee;
+
+}
+
+.pageEditorDetailContainerIE {
+    /* background-color: #eeeeee; */
+    /* if background-color is set, IE6 and IE7 will not render rounded corner border for fieldset node */
+    /*    the reason fieldset is used here is to make it possible to get rounded corners in IE */
+}
+
+.layoutEdgeTop {
+    clear: both;
+    height: 30px;
+
+    display: none;
+}
+
+.layoutEdgeBottom {
+    clear: both;
+    height: 30px;
+
+    display: none;
+}
+
+.ieLayoutBackgroundIFrame {
+    position: absolute;
+    display: none;
+
+    left: 0px;
+    top: 0px;
+    width: 100%;
+    height: 100%;
+
+    z-index: -1;
+
+    filter: Alpha(Opacity="100");
+}
+
+
+.layoutEdgeTopTest {
+    width: 100%;
+    height: 20px;
+    display: block;
+
     /*background-color: #d3d3d3;*/
-    /*  ^^ set conditionally in code - in IE6, if fieldset background-color is set, fieldset is rendered poorly */
+
     -moz-border-radius: 5px;
     -moz-border-top-colors: ThreeDLightShadow ThreeDHighlight;
     -moz-border-right-colors: ThreeDDarkShadow ThreeDShadow;
     -moz-border-bottom-colors: ThreeDDarkShadow ThreeDShadow;
     -moz-border-left-colors: ThreeDLightShadow ThreeDHighlight;
+
+    border-bottom-color: #000;
+    border-bottom-style: groove;
+    border-bottom-width: 2px;
+    border-collapse: separate;
+    border-left-color: #000;
+    border-left-style: groove;
+    border-left-width: 2px;
+    border-right-color: #000;
+    border-right-style: groove;
+    border-right-width: 2px;
+    border-top-color: #000;
+    border-top-style: groove;
+    border-top-width: 2px;
+
+    padding: 0.35em 0.62em 0.75em;
+    background-color: transparent;
 }
 
-.pageEditorDetailContainer {
-    padding: 0.35em 0.625em 0.75em 0.625em;
-    /*background-color: #eeeeee;*/
-    /*  ^^ set conditionally in code - in IE6, if fieldset background-color is set, fieldset is rendered poorly */
+.layoutEdgeBottomTest {
+    width: 100%;
+    height: 20px;
+    display: block;
+
+    /*background-color: #d3d3d3;*/
+
     -moz-border-radius: 5px;
     -moz-border-top-colors: ThreeDLightShadow ThreeDHighlight;
     -moz-border-right-colors: ThreeDDarkShadow ThreeDShadow;
     -moz-border-bottom-colors: ThreeDDarkShadow ThreeDShadow;
     -moz-border-left-colors: ThreeDLightShadow ThreeDHighlight;
 
-    float: left;
-    margin-right: 10px;
-    margin-bottom: 10px;
+    border-bottom-color: #000;
+    border-bottom-style: groove;
+    border-bottom-width: 2px;
+    border-collapse: separate;
+    border-left-color: #000;
+    border-left-style: groove;
+    border-left-width: 2px;
+    border-right-color: #000;
+    border-right-style: groove;
+    border-right-width: 2px;
+    border-top-color: #000;
+    border-top-style: groove;
+    border-top-width: 2px;
+
+    padding: 0.35em 0.62em 0.75em;
+    background-color: transparent;
 }
 

Modified: portals/jetspeed-2/branches/JETSPEED-2.1.3/src/webapp/javascript/jetspeed/widget/PageEditor.html
URL: http://svn.apache.org/viewvc/portals/jetspeed-2/branches/JETSPEED-2.1.3/src/webapp/javascript/jetspeed/widget/PageEditor.html?rev=583998&r1=583997&r2=583998&view=diff
==============================================================================
--- portals/jetspeed-2/branches/JETSPEED-2.1.3/src/webapp/javascript/jetspeed/widget/PageEditor.html (original)
+++ portals/jetspeed-2/branches/JETSPEED-2.1.3/src/webapp/javascript/jetspeed/widget/PageEditor.html Thu Oct 11 17:36:12 2007
@@ -18,15 +18,16 @@
       dojo will look for a body tag and use its content -->
 <body>
 <div class="pageEditorPane">
+
     <div dojoAttachPoint="containerNode" class="container"></div>
 
     <div dojoAttachPoint="deletePortletDialog">
 		<div class="container" dojoAttachPoint="deletePortletDialogBg">
 			<div class="deletePortletDialog" dojoAttachPoint="deletePortletDialogFg">
-				<h2>Are you sure you want to delete this portlet?</h2>
+				<h2>${this.dialogLabels.removeportlet}</h2>
                 <div dojoAttachPoint="deletePortletTitle">&nbsp;</div>
-                <button dojoType="Button" dojoAttachEvent="onClick:deletePortletConfirmed">OK</button>
-                <button dojoType="Button" dojoAttachPoint="deletePortletCancel">Cancel</button>
+                <button dojoType="Button" dojoAttachEvent="onClick:deletePortletConfirmed">${this.dialogLabels.ok}</button>
+                <button dojoType="Button" dojoAttachPoint="deletePortletCancel">${this.dialogLabels.cancel}</button>
 				<p></p>
 			</div>
 		</div>
@@ -35,10 +36,10 @@
     <div dojoAttachPoint="deleteLayoutDialog">
 		<div class="container" dojoAttachPoint="deleteLayoutDialogBg">
 			<div class="deleteLayoutDialog" dojoAttachPoint="deleteLayoutDialogFg">
-				<h2>Are you sure you want to delete this layout?</h2>
+				<h2>${this.dialogLabels.deletelayout}</h2>
                 <div dojoAttachPoint="deleteLayoutTitle">&nbsp;</div>
-                <button dojoType="Button" dojoAttachEvent="onClick:deleteLayoutConfirmed">OK</button>
-                <button dojoType="Button" dojoAttachPoint="deleteLayoutCancel">Cancel</button>
+                <button dojoType="Button" dojoAttachEvent="onClick:deleteLayoutConfirmed">${this.dialogLabels.ok}</button>
+                <button dojoType="Button" dojoAttachPoint="deleteLayoutCancel">${this.dialogLabels.cancel}</button>
 				<p></p>
 			</div>
 		</div>
@@ -47,33 +48,33 @@
 	<div dojoAttachPoint="columnSizeDialog">
 		<div class="container" dojoAttachPoint="columnSizeDialogBg">
 			<div class="columnSizeDialog" dojoAttachPoint="columnSizeDialogFg">
-				<h2>Change Column Sizes</h2>
+				<h2>${this.dialogLabels.columnsizes}</h2>
                 <div dojoAttachPoint="spinner0Field" class="columnSizeField">
-                    <div>Column 1</div>
+                    <div>${this.dialogLabels.columnsizes_column1}</div>
                     <input dojoType="IntegerSpinner" dojoAttachPoint="spinner0" value="0" delta="1" min="0" max="100" separator="," maxlength="10" >
                 </div>
                 <div dojoAttachPoint="spinner1Field" class="columnSizeField">
-                    <div>Column 2</div>
+                    <div>${this.dialogLabels.columnsizes_column2}</div>
                     <input dojoType="IntegerSpinner" dojoAttachPoint="spinner1" value="0" delta="1" min="0" max="100" separator="," maxlength="10" >
                 </div>
                 <div dojoAttachPoint="spinner2Field" class="columnSizeField">
-                    <div>Column 3</div>
+                    <div>${this.dialogLabels.columnsizes_column3}</div>
                     <input dojoType="IntegerSpinner" dojoAttachPoint="spinner2" value="0" delta="1" min="0" max="100" separator="," maxlength="10" >
                 </div>
                 <div dojoAttachPoint="spinner3Field" class="columnSizeField">
-                    <div>Column 4</div>
+                    <div>${this.dialogLabels.columnsizes_column4}</div>
                     <input dojoType="IntegerSpinner" dojoAttachPoint="spinner3" value="0" delta="1" min="0" max="100" separator="," maxlength="10" >
                 </div>
                 <div dojoAttachPoint="spinner4Field" class="columnSizeField">
-                    <div>Column 5</div>
+                    <div>${this.dialogLabels.columnsizes_column5}</div>
                     <input dojoType="IntegerSpinner" dojoAttachPoint="spinner4" value="0" delta="1" min="0" max="100" separator="," maxlength="10" >
                 </div>
-                <button dojoType="Button" dojoAttachEvent="onClick:columnSizeConfirmed">OK</button>
-                <button dojoType="Button" dojoAttachPoint="columnSizeCancel">Cancel</button>
+                <button dojoType="Button" dojoAttachEvent="onClick:columnSizeConfirmed">${this.dialogLabels.ok}</button>
+                <button dojoType="Button" dojoAttachPoint="columnSizeCancel">${this.dialogLabels.cancel}</button>
                 <p></p>
 			</div>
 		</div>
 	</div>
 
 </div>
-</body>
\ No newline at end of file
+</body>



---------------------------------------------------------------------
To unsubscribe, e-mail: jetspeed-dev-unsubscribe@portals.apache.org
For additional commands, e-mail: jetspeed-dev-help@portals.apache.org


Mime
View raw message