Author: jmorliaguet Date: Fri May 26 13:50:25 2006 New Revision: 3222 Modified: cpsskins/branches/paris-sprint-2006/ui/screens/definitions.py cpsskins/branches/paris-sprint-2006/ui/screens/editor.pt cpsskins/branches/paris-sprint-2006/ui/screens/sitemanager/io.pt cpsskins/branches/paris-sprint-2006/ui/screens/sitemanager/settings.pt
Log: - simplifications / added some comments on the various MVC components Modified: cpsskins/branches/paris-sprint-2006/ui/screens/definitions.py ============================================================================== --- cpsskins/branches/paris-sprint-2006/ui/screens/definitions.py (original) +++ cpsskins/branches/paris-sprint-2006/ui/screens/definitions.py Fri May 26 13:50:25 2006 @@ -4,11 +4,14 @@ _ = MessageFactory('cpsskins') MODELS = { + + # the stylesheet in which the styles created with the editor are rendered 'stylesheet': { 'id': 'stylesheet', 'data': {} }, + # the main editor's action buttons 'action-pad': { 'id': 'action-pad', 'data': { @@ -16,6 +19,7 @@ } }, + # the element editor 'element-editor': { 'id': 'element-editor', 'data': { @@ -30,6 +34,7 @@ } }, + # the setting editor in the site manager screen 'setting-editor': { 'id': 'setting-editor', 'data': { @@ -44,6 +49,7 @@ } }, + # the perspective selector widget at the top right of the screen 'perspective-selector': { 'id': 'perspective-selector', 'data': { @@ -51,6 +57,7 @@ } }, + # the theme selection tabs 'theme-tabs': { 'id': 'theme-tabs', 'data': { @@ -58,6 +65,7 @@ } }, + # the page selection tabs 'page-tabs': { 'id': 'page-tabs', 'data': { @@ -65,13 +73,8 @@ } }, - 'page-designer': { - 'id': 'page-designer', - 'data': { - 'url': '@@page-designer.html', - } - }, + # the location selection widget at the top of the canvas editing area 'location-selector': { 'id': 'location-selector', 'data': { @@ -79,39 +82,7 @@ } }, - 'wysiwyg-mode': { - 'id': 'wysiwyg-mode', - 'data': { - 'url': '@@renderPage.html', - 'form': { - 'engine': 'wysiwyg', - }, - 'css': '++resource++wysiwyg-mode.css', - } - }, - - 'layout-mode': { - 'id': 'layout-mode', - 'data': { - 'url': '@@renderPage.html', - 'form': { - 'engine': 'layout', - }, - 'css': '++resource++layout-mode.css', - } - }, - - 'content-author': { - 'id': 'content-author', - 'data': { - 'url': '@@renderPage.html', - 'form': { - 'engine': 'content-author', - }, - 'css': '++resource++content-author.css', - } - }, - + # the site manager screen 'site-manager': { 'id': 'site-manager', 'data': { @@ -120,13 +91,7 @@ } }, - 'portlet-factory': { - 'id': 'portlet-factory', - 'data': { - 'url': '@@portletFactory.html', - }, - }, - + # the settings panel 'settings': { 'id': 'settings', 'data': { @@ -134,6 +99,7 @@ } }, + # the setting section panel 'settings-section': { 'id': 'settings-section', 'data': { @@ -142,6 +108,15 @@ } }, + # the negotiation panel + 'negotiation': { + 'id': 'negotiation', + 'data': { + 'url': '@@negotiation.html', + } + }, + + # the I/O panel 'io': { 'id': 'io', 'data': { @@ -149,6 +124,7 @@ } }, + # the I/O section panel 'io-section': { 'id': 'io-section', 'data': { @@ -157,16 +133,63 @@ } }, - 'negotiation': { - 'id': 'negotiation', + # the page designer screen + 'page-designer': { + 'id': 'page-designer', 'data': { - 'url': '@@negotiation.html', + 'url': '@@page-designer.html', } }, + # the page rendered in WYSIWYG mode + 'wysiwyg-mode': { + 'id': 'wysiwyg-mode', + 'data': { + 'url': '@@renderPage.html', + 'form': { + 'engine': 'wysiwyg', + }, + 'css': '++resource++wysiwyg-mode.css', + } + }, + + # the page rendered in layout mode + 'layout-mode': { + 'id': 'layout-mode', + 'data': { + 'url': '@@renderPage.html', + 'form': { + 'engine': 'layout', + }, + 'css': '++resource++layout-mode.css', + } + }, + + # the content author screen + 'content-author': { + 'id': 'content-author', + 'data': { + 'url': '@@renderPage.html', + 'form': { + 'engine': 'content-author', + }, + 'css': '++resource++content-author.css', + } + }, + + # the portlet factory at the bottom of the screen + 'portlet-factory': { + 'id': 'portlet-factory', + 'data': { + 'url': '@@portletFactory.html', + }, + }, + } VIEWS = { + + # the stylesheet widget in <head></head> 'stylesheet': { 'id': 'stylesheet', 'widget': { @@ -175,10 +198,10 @@ 'model': 'stylesheet', 'perspectives': ['page-designer', 'content-author', 'element-editor'], - 'controllers': ['main-editor-perspectives', 'element-editor-actions'], + 'controllers': ['main-editor-perspectives', 'main-editor-actions'], }, - # Top area + # the main editor action buttons 'action-pad': { 'id': 'action-pad', 'widget': { @@ -190,6 +213,7 @@ 'controllers': ['main-editor-perspectives'], }, + # the element editor panel 'element-editor': { 'id': 'element-editor', 'widget': { @@ -200,6 +224,7 @@ 'controllers': ['main-editor-perspectives'], }, + # the setting editor panel 'setting-editor': { 'id': 'setting-editor', 'widget': { @@ -210,6 +235,7 @@ 'controllers': ['site-manager-perspectives'], }, + # the tooltip widget 'tooltip': { 'id': 'tooltip', 'selectors': ['.actionPad a'], @@ -228,6 +254,7 @@ 'controllers': ['show-hide-tooltip'], }, + # the perspective selector widget 'perspective-selector': { 'id': 'perspective-selector', 'widget': { @@ -239,7 +266,7 @@ 'controllers': ['main-editor-perspectives', 'main-editor-actions'], }, - # Main area + # the horizontal tabs to select the work theme 'theme-tabs': { 'id': 'theme-tabs', 'widget': { @@ -250,6 +277,7 @@ 'controllers': ['main-editor-perspectives', 'main-editor-actions'], }, + # the horizontal tabs to select the work page 'page-tabs': { 'id': 'page-tabs', 'widget': { @@ -260,6 +288,7 @@ 'controllers': ['main-editor-perspectives', 'main-editor-actions'], }, + # the page designer panel 'page-designer': { 'id': 'page-designer', 'widget': { @@ -270,6 +299,7 @@ 'controllers': ['main-editor-perspectives'], }, + # the location selection widget 'location-selector': { 'id': 'location-selector', 'widget': { @@ -308,6 +338,7 @@ 'portlet-factory', 'main-editor-actions'], }, + # the content author screen 'content-author': { 'id': 'content-author', 'widget': { @@ -315,11 +346,11 @@ }, 'model': 'content-author', 'perspectives': ['content-author'], - 'controllers': ['main-editor-perspectives', 'element-mover', + 'controllers': ['main-editor-perspectives', 'element-mover', 'portlet-factory', 'main-editor-actions'], }, - # screen + # the site manager screen 'site-manager': { 'id': 'site-manager', 'widget': { @@ -348,7 +379,7 @@ }, 'model': 'settings-section', 'perspectives': ['settings'], - 'controllers': ['site-manager-perspectives', 'settings-actions'], + 'controllers': ['site-manager-perspectives', 'main-editor-actions'], }, 'negotiation': { @@ -378,7 +409,7 @@ }, 'model': 'io-section', 'perspectives': ['io'], - 'controllers': ['site-manager-perspectives', 'io-actions'], + 'controllers': ['site-manager-perspectives', 'main-editor-actions'], }, # element editor @@ -389,7 +420,7 @@ }, 'model': 'element-editor', 'perspectives': ['element-editor'], - 'controllers': ['main-editor-perspectives', 'element-editor-actions'], + 'controllers': ['main-editor-perspectives', 'main-editor-actions'], }, # Bottom area @@ -471,40 +502,35 @@ CONTROLLERS = { + # main editor perspectives: + # [Site manager] [Page designer] [Content author] 'main-editor-perspectives': { 'id': 'main-editor-perspectives', 'type': 'perspective selector', - 'initial': 'site-manager', - }, - - 'main-editor-actions': { - 'id': 'main-editor-actions', - 'type': 'remote scripting', + 'initial': 'page-manager', }, + # site manager perspectives: settings | negotiation | Import / export 'site-manager-perspectives': { 'id': 'site-manager-perspectives', 'type': 'perspective selector', 'initial': 'settings', }, + # page designer perspectives: [Layout] [WYSIWYG] 'page-mode-perspectives': { 'id': 'page-mode-perspectives', 'type': 'perspective selector', - 'initial': 'layout', - }, - - 'element-editor-perspectives': { - 'id': 'element-editor-perspectives', - 'type': 'perspective selector', - 'initial': 'default', + 'initial': 'wysiwyg', }, + # tooltip 'show-hide-tooltip': { 'id': 'show-hide-tooltip', 'type': 'focus observer', }, + # portlet factory at the bottom of the screen [ ][ ][ ][ ] ... 'portlet-factory': { 'id': 'portlet-factory', 'type': 'drag-and-drop', @@ -528,6 +554,7 @@ }, }, + # drag-and-drop for elements on the canvas 'element-mover': { 'id': 'element-mover', 'type': 'drag-and-drop', @@ -546,28 +573,21 @@ }, }, + # contextual menu action handlers 'menu-actions': { 'id': 'menu-actions', 'type': 'command', }, + # show / hide the contextual menu 'show-hide-menu': { 'id': 'show-hide-menu', 'type': 'focus observer', }, - 'settings-actions': { - 'id': 'settings-actions', - 'type': 'remote scripting', - }, - - 'io-actions': { - 'id': 'io-actions', - 'type': 'remote scripting', - }, - - 'element-editor-actions': { - 'id': 'element-editor-actions', + # remote scripting for the main editor area + 'main-editor-actions': { + 'id': 'main-editor-actions', 'type': 'remote scripting', }, Modified: cpsskins/branches/paris-sprint-2006/ui/screens/editor.pt ============================================================================== --- cpsskins/branches/paris-sprint-2006/ui/screens/editor.pt (original) +++ cpsskins/branches/paris-sprint-2006/ui/screens/editor.pt Fri May 26 13:50:25 2006 @@ -67,7 +67,6 @@ <!-- element editor --> <ins class="model" cite="@@getModel?id=element-editor"></ins> <ins class="view" cite="@@getView?id=element-editor"></ins> - <ins class="controller" cite="@@getController?id=element-editor-actions"></ins> </div> Modified: cpsskins/branches/paris-sprint-2006/ui/screens/sitemanager/io.pt ============================================================================== --- cpsskins/branches/paris-sprint-2006/ui/screens/sitemanager/io.pt (original) +++ cpsskins/branches/paris-sprint-2006/ui/screens/sitemanager/io.pt Fri May 26 13:50:25 2006 @@ -20,7 +20,6 @@ <td class="subsection"> <ins class="model" cite="@@getModel?id=io-section"></ins> <ins class="view" cite="@@getView?id=io-section"></ins> - <ins class="controller" cite="@@getController?id=io-actions"></ins> </td> </tr> </table> Modified: cpsskins/branches/paris-sprint-2006/ui/screens/sitemanager/settings.pt ============================================================================== --- cpsskins/branches/paris-sprint-2006/ui/screens/sitemanager/settings.pt (original) +++ cpsskins/branches/paris-sprint-2006/ui/screens/sitemanager/settings.pt Fri May 26 13:50:25 2006 @@ -23,7 +23,6 @@ <td class="subsection"> <ins class="model" cite="@@getModel?id=settings-section"></ins> <ins class="view" cite="@@getView?id=settings-section"></ins> - <ins class="controller" cite="@@getController?id=settings-actions"></ins> </td> </tr> </table> -- http://lists.nuxeo.com/mailman/listinfo/z3lab-checkins