From 4251c752d81e0b0db9c181da2eaf37c074a61fb3 Mon Sep 17 00:00:00 2001 From: Kay Strobach Date: Sun, 24 Jul 2011 10:31:39 +0200 Subject: [PATCH] [FEATURE] Add ExtJS xtype:modulepanel for BE Modules This is a follow up change to #12664. It adds a new Extjs xtype called modulepanel and the required styles. This way we can have extjs modules which fit the TYPO3 look'n'feel. The CSS modifies the tbar and the bbar to look like the standard toolbars in TYPO3. 4.5 is added to releases, as #12644 is the direct parent. Change-Id: I596962fc81e66368db06059447b2f6a09db4ff73 Resolves: #28384 Releases: 4.6, 4.5 Reviewed-on: http://review.typo3.org/3696 Reviewed-by: Georg Ringer Reviewed-by: Philipp Gampe Tested-by: Philipp Gampe Reviewed-by: Steffen Kamper Tested-by: Steffen Kamper --- typo3/backend.php | 1 + typo3/js/extjs/modulepanel.js | 45 +++++++++++++++++++++ typo3/sysext/t3skin/extjs/xtheme-t3skin.css | 9 +++++ 3 files changed, 55 insertions(+) create mode 100644 typo3/js/extjs/modulepanel.js diff --git a/typo3/backend.php b/typo3/backend.php index 52fd7249bd42..bb979acfa523 100644 --- a/typo3/backend.php +++ b/typo3/backend.php @@ -132,6 +132,7 @@ class TYPO3backend { 'debugPanel' => 'js/extjs/debugPanel.js', 'viewport' => 'js/extjs/viewport.js', 'iframepanel' => 'js/extjs/iframepanel.js', + 'modulepanel' => 'js/extjs/modulepanel.js', 'viewportConfiguration' => 'js/extjs/viewportConfiguration.js', 'util' => '../t3lib/js/extjs/util.js', ); diff --git a/typo3/js/extjs/modulepanel.js b/typo3/js/extjs/modulepanel.js new file mode 100644 index 000000000000..6e5bf552fdf2 --- /dev/null +++ b/typo3/js/extjs/modulepanel.js @@ -0,0 +1,45 @@ +/*************************************************************** +* Copyright notice +* +* (c) 2011 Kay Strobach +* All rights reserved +* +* This script is part of the TYPO3 project. The TYPO3 project is +* free software; you can redistribute it and/or modify +* it under the terms of the GNU General Public License as published by +* the Free Software Foundation; either version 2 of the License, or +* (at your option) any later version. +* +* The GNU General Public License can be found at +* http://www.gnu.org/copyleft/gpl.html. +* A copy is found in the textfile GPL.txt and important notices to the license +* from the author is found in LICENSE.txt distributed with these scripts. +* +* +* This script is distributed in the hope that it will be useful, +* but WITHOUT ANY WARRANTY; without even the implied warranty of +* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +* GNU General Public License for more details. +* +* This copyright notice MUST APPEAR in all copies of the script! +***************************************************************/ + +TYPO3.modulePanel = Ext.extend(Ext.Panel, { + name: 'modulePanel', + maskMessage: ' ', + doMask: true, + border: false, + // component build + initComponent: function() { + Ext.apply(this, { + tbarCfg: { + cls: 't3skin-typo3-module-panel-toolbar' + }, + bbarCfg: { + cls: 't3skin-typo3-module-panel-toolbar' + } + }); + TYPO3.modulePanel.superclass.initComponent.apply(this, arguments); + } +}); +Ext.reg('modulePanel', TYPO3.modulePanel); \ No newline at end of file diff --git a/typo3/sysext/t3skin/extjs/xtheme-t3skin.css b/typo3/sysext/t3skin/extjs/xtheme-t3skin.css index 3b12367a3e97..e0fe555c7876 100644 --- a/typo3/sysext/t3skin/extjs/xtheme-t3skin.css +++ b/typo3/sysext/t3skin/extjs/xtheme-t3skin.css @@ -2380,3 +2380,12 @@ div.x-grid3-row:hover img.t3-icon-extensions-workspaces { width: 17px } +.t3skin-typo3-module-panel-toolbar .x-toolbar{ + background-color: #585858; + background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAMAAAABCAYAAAAb4BS0AAAAGElEQVR42gENAPL/AEBAQExAQECzQEBA/xb3BD8CHBN0AAAAAElFTkSuQmCC"); + background-position: right; + background-repeat: repeat-y; + border: none; + padding: 0; + margin: 0; +} \ No newline at end of file -- 2.20.1