Exemplo n.º 1
0
    def process(self, request):
        """
        Process the request arguments from the web server to see if any
        apply to this block
        """
        self.idevice.message = ""
        Block.process(self, request)
        
        self.titleElement.process(request)

        self.questionOrderChoiceElement.process(request)
        self.timerChoiceElement.process(request)

        self.idevice.uploadNeededScripts()

        if "addClickableArea" + unicode(self.id) in request.args:
            self.idevice.addClickableField()
            self.idevice.edit = True
            self.idevice.undo = False

        for textAreaFieldName, textAreaElement in self.mainTextAreaElements.iteritems():
            textAreaElement.process(request)

        for textFieldName, textElement in self.mainTextElements.iteritems():
            textElement.process(request)

        for clickableAreaElement in self.clickableAreaElements:
            clickableAreaElement.process(request)
            
            
        #validate integer fields are actually integers
        field_engine_check_fields_are_ints(self.mainTextElements, \
                            ["width", "height", "hintWidth", "hintHeight"], thisIdevice=self.idevice)
Exemplo n.º 2
0
    def process(self, request):
        """
        Process the request arguments from the web server to see if any
        apply to this block
        """
        self.idevice.message = ""
        Block.process(self, request)

        self.titleElement.process(request)

        self.questionOrderChoiceElement.process(request)
        self.timerChoiceElement.process(request)

        self.idevice.uploadNeededScripts()

        if "addClickableArea" + unicode(self.id) in request.args:
            self.idevice.addClickableField()
            self.idevice.edit = True
            self.idevice.undo = False

        for textAreaFieldName, textAreaElement in self.mainTextAreaElements.iteritems(
        ):
            textAreaElement.process(request)

        for textFieldName, textElement in self.mainTextElements.iteritems():
            textElement.process(request)

        for clickableAreaElement in self.clickableAreaElements:
            clickableAreaElement.process(request)

        #validate integer fields are actually integers
        field_engine_check_fields_are_ints(self.mainTextElements, \
                            ["width", "height", "hintWidth", "hintHeight"], thisIdevice=self.idevice)
Exemplo n.º 3
0
 def process(self, request):
     #see if its time to delete ourselves
     self.field.message = ""
     
     if "action" in request.args and request.args["action"][0] == self.id:
         self.field.idevice.clickableAreaFields.remove(self.field)
         
     for textElementName, textElement in self.textElements.iteritems():
         textElement.process(request)
     for textAreaElementName, textAreaElement in self.textAreaElements.iteritems():
         textAreaElement.process(request)
     
     errMsg = field_engine_check_fields_are_ints(self.textElements, \
                 ['top', 'left', 'width', 'height', 'hideDelay'], None, self.field.idevice, self.field)
Exemplo n.º 4
0
    def process(self, request):
        #see if its time to delete ourselves
        self.field.message = ""

        if "action" in request.args and request.args["action"][0] == self.id:
            self.field.idevice.clickableAreaFields.remove(self.field)

        for textElementName, textElement in self.textElements.iteritems():
            textElement.process(request)
        for textAreaElementName, textAreaElement in self.textAreaElements.iteritems(
        ):
            textAreaElement.process(request)

        errMsg = field_engine_check_fields_are_ints(self.textElements, \
                    ['top', 'left', 'width', 'height', 'hideDelay'], None, self.field.idevice, self.field)