예제 #1
0
    def getRange(self):
        if self.m_lastRange is None:
            self.getSelection()
            return Selection.getRange()

        else:
            return self.m_lastRange
예제 #2
0
파일: RichTextEditor.py 프로젝트: Afey/pyjs
    def getRange(self):
        if self.m_lastRange is None:
            self.getSelection()
            return Selection.getRange()

        else:
            return self.m_lastRange
예제 #3
0
    def captureSelection(self):
        try:
            self.getSelection()
            self.m_lastRange = Selection.getRange()

        except:
            GWT.log("Error capturing selection for IE", ex)
예제 #4
0
파일: RichTextEditor.py 프로젝트: Afey/pyjs
    def captureSelection(self):
        try:
            self.getSelection()
            self.m_lastRange = Selection.getRange()

        except:
            GWT.log("Error capturing selection for IE", ex)
예제 #5
0
    def run(self):
        try:
            self.getSelection()
            rng = Selection.getRange()
            if (self.timerRange is None) or (not self.timerRange.equals(rng)):
                self.onSelectionChange(rng)
                self.timerRange = rng

        except:
            GWT.log("Error in timer selection", ex)
예제 #6
0
    def run(self):
        try:
            self.getSelection()
            rng = Selection.getRange()
            if (self.timerRange is None) or (not self.timerRange.equals(rng)):
                self.onSelectionChange(rng)
                self.timerRange = rng

        except:
            GWT.log("Error in timer selection", ex)
예제 #7
0
    def captureSelection(self):
        """ This captures the selection when the mouse leaves the RTE,
            because in IE the selection indicating the cursor position
            is lost once another widget gains focus.
            Could be implemented for IE only.
        """
        try:
            self.getSelection()
            self.lastRange = Selection.getRange()

        except:
            GWT.log("Error capturing selection for IE", ex)
예제 #8
0
    def captureSelection(self):
        """ This captures the selection when the mouse leaves the RTE,
            because in IE the selection indicating the cursor position
            is lost once another widget gains focus.
            Could be implemented for IE only.
        """
        try:
            self.getSelection()
            self.lastRange = Selection.getRange()

        except:
            GWT.log("Error capturing selection for IE", ex)