From cd651b8b8cfda37b5b31dc3c7cd36a75811b9369 Mon Sep 17 00:00:00 2001 From: Francois Suter Date: Tue, 19 Apr 2011 13:51:27 +0200 Subject: [PATCH] [BUGFIX] Force icon overlay for deleted records t3lib_iconWorks::mapRecordOverlayToSpriteIconName() defines the overlays to display for any given record icon, but it not workspace- aware. However a pending request adds a hook to override the icon overlays. This enables the "version" extension to hook into the process and force the overlays to "deleted" when the current record's t3ver_state = 2 (i.e. it is deleted in a workspace). Test in conjunction with https://review.typo3.org/#change,1459 Change-Id: I63793da2450dbf5113218441713a5edb79e6f21d Resolves: #24641 Releases: 4.6, 4.5 --- .../version/class.tx_version_iconworks.php | 51 +++++++++++++++++++ typo3/sysext/version/ext_localconf.php | 2 + 2 files changed, 53 insertions(+) create mode 100644 typo3/sysext/version/class.tx_version_iconworks.php diff --git a/typo3/sysext/version/class.tx_version_iconworks.php b/typo3/sysext/version/class.tx_version_iconworks.php new file mode 100644 index 000000000000..46ced3e03a5c --- /dev/null +++ b/typo3/sysext/version/class.tx_version_iconworks.php @@ -0,0 +1,51 @@ + \ No newline at end of file diff --git a/typo3/sysext/version/ext_localconf.php b/typo3/sysext/version/ext_localconf.php index 107bf08cf910..df6c04d18c19 100644 --- a/typo3/sysext/version/ext_localconf.php +++ b/typo3/sysext/version/ext_localconf.php @@ -8,6 +8,8 @@ if (!defined ('TYPO3_MODE')) { // register the hook to actually do the work within TCEmain $GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['t3lib/class.t3lib_tcemain.php']['processCmdmapClass']['version'] = t3lib_extMgm::extPath('version', 'class.tx_version_tcemain.php:&tx_version_tcemain'); $GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['t3lib/class.t3lib_tcemain.php']['moveRecordClass']['version'] = t3lib_extMgm::extPath('version', 'class.tx_version_tcemain.php:&tx_version_tcemain'); + // Register hook for overriding the icon status overlay +$GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['t3lib/class.t3lib_iconworks.php']['overrideIconOverlay']['version'] = t3lib_extMgm::extPath('version', 'class.tx_version_iconworks.php:&tx_version_iconworks'); if (TYPO3_MODE == 'BE') { -- 2.20.1