~azzar1/unity/add-show-desktop-key

« back to all changes in this revision

Viewing changes to ivle/webapp/console/__init__.py

  • Committer: David Coles
  • Date: 2009-08-03 00:32:10 UTC
  • mto: (1294.2.119 ui-the-third)
  • mto: This revision was merged to the branch mainline in revision 1353.
  • Revision ID: coles.david@gmail.com-20090803003210-65k1ht95rkkkqujv
Fix Console breakage due to ConsoleView's class varibiles being overwritten by the parent class' init function.

Show diffs side-by-side

added added

removed removed

Lines of Context:
9
9
    tab = 'console'
10
10
    help = 'Console'
11
11
 
12
 
    plugin_scripts = {'ivle.webapp.console': ['console.js']}
13
 
    plugin_styles  = {'ivle.webapp.console': ['console.css']}
14
 
    plugin_scripts_init = ['console_init']
15
 
 
16
 
    # Don't load the console overlay when we already have a console.
17
 
    overlay_blacklist = [ConsoleOverlay]
 
12
    # Overide the the standard constructor view
 
13
    def __init__(self, *args, **kwargs):
 
14
        super(ConsoleView, self).__init__(*args, **kwargs)
 
15
 
 
16
        self.plugin_scripts = {'ivle.webapp.console': ['console.js']}
 
17
        self.plugin_styles  = {'ivle.webapp.console': ['console.css']}
 
18
        self.plugin_scripts_init = ['console_init']
 
19
 
 
20
        # Don't load the console overlay when we already have a console.
 
21
        self.overlay_blacklist = [ConsoleOverlay]
18
22
 
19
23
    def authorize(self, req):
20
24
        return req.user is not None