Project

General

Profile

Revision 4a49ed53

ID4a49ed5356cecc7120c156ee8576975bc71b911f
Parent 7b54a690
Child d32489ac

Added by Thomas ANDREJAK about 15 years ago

Restauration du egg et début de correction pylint

git-svn-id: https://vigilo-dev.si.c-s.fr/svn@280 b22e2e97-25c9-44ff-b637-2e5ceca36478

View differences:

README/README_jquery/ui_dialog.py
1
# -*- coding: utf-8 -*-
2
# vim:set expandtab tabstop=4 shiftwidth=4:
3

  
1 4
# Permission is hereby granted, free of charge, to any person obtaining a copy
2 5
# of this software and associated documentation files (the "Software"), to deal
3 6
# in the Software without restriction, including without limitation the rights
......
16 19
# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
17 20
# THE SOFTWARE.
18 21

  
19
from tw.api import Widget, JSLink, CSSLink, js_function, js_callback
20
from tw.jquery import JQuery
21
from tw.jquery.direction import *
22
from tw.forms import FormField
22
from tw.api import Widget, CSSLink, js_function
23
from tw.jquery.direction import jquery_direction_js
23 24
from ui_core import jquery_ui_core_js
24 25
from ui import ui_dialog_js , ui_draggable_js, ui_resizable_js
25 26

  
26 27
__all__ = ["jquery_ui_dialog_js"]
27 28

  
28
jquery_ui_dialog_css    = CSSLink(modname=__name__, filename='static/css/ui.all.css')
29
jquery_ui_dialog_css    = CSSLink(modname=__name__,
30
		filename='static/css/ui.all.css')
29 31

  
30 32
jQuery = js_function('jQuery')
31 33

  
32 34
class JQueryUIDialog(Widget):
33 35
    
34
    javascript = [ui_dialog_js,ui_draggable_js,jquery_ui_core_js,jquery_direction_js,ui_resizable_js]
35
    css=[jquery_ui_dialog_css]
36
    """Generate an instance for an UI Dialog"""
37

  
38
    javascript = [ui_dialog_js,ui_draggable_js,jquery_ui_core_js,
39
		    jquery_direction_js,ui_resizable_js]
40
    css = [jquery_ui_dialog_css]
36 41
    
37
    params = ["autoOpen","bgiframe","buttons","closeOnEscape","dialogClass"
38
	"draggable","height","hide","maxHeight","maxWidht","minHeight","minWidth"
39
	"modal","position","resizable","show","stack","title","width","zindex" ]
42
    params = ['autoOpen', 'bgiframe', 'buttons', 'closeOnEscape', 'dialogClass'
43
	'draggable', 'height', 'hide', 'maxHeight', 'maxWidht', 'minHeight', 'minWidth'
44
	'modal', 'position', 'resizable', 'show', 'stack', 'title', 'width', 'zindex' ]
40 45
   
41 46
    autoOpen = True
42 47
    bgiframe = False
......
58 63
    title = ''
59 64
    width = "auto"
60 65
    zindex = 1000
66

  
61 67
    def update_params(self, d):
68
        
69
        """Allow the user to update the UI Dialog parameters"""
70

  
62 71
        super(JQueryUIDialog, self).update_params(d)
63
        if not getattr(d,"id",None):
72
        
73
        if not getattr(d, "id", None):
64 74
            raise ValueError, "JQueryUIDialog is supposed to have id"
65
    	dialog_params = dict (     autoOpen = self.autoOpen,
75
    	
76
        dialog_params = dict (     autoOpen = self.autoOpen,
66 77
			bgiframe = self.bgiframe,
67 78
			buttons = self.buttons,
68 79
			closeOnEscape = self.closeOnEscape,

Also available in: Unified diff