source: products/quintagroup.plonetabs/branches/nokss/quintagroup/plonetabs/setuphandlers.py @ 3681

Last change on this file since 3681 was 3437, checked in by potar, 9 years ago

Merged tests branch

  • Property svn:eol-style set to native
File size: 575 bytes
Line 
1from Products.CMFCore.utils import getToolByName
2
3
4def cleanUpControlPanel(portal, out):
5    cpt = getToolByName(portal, 'portal_controlpanel')
6    if 'plonetabs' in [o.id for o in cpt.listActions()]:
7        cpt.unregisterConfiglet('plonetabs')
8        out.append('plonetabs configlet unregistered.')
9
10
11def uninstall(context):
12    # Only run step if a flag file is present (e.g. not an extension profile)
13    if context.readDataFile('quintagroup.plonetabs-uninstall.txt') is None:
14        return
15    out = []
16    site = context.getSite()
17
18    cleanUpControlPanel(site, out)
Note: See TracBrowser for help on using the repository browser.