~ubuntu-branches/ubuntu/oneiric/request-tracker3.8/oneiric-updates

« back to all changes in this revision

Viewing changes to share/html/NoAuth/RichText/FCKeditor/editor/_source/commandclasses/fckfitwindow.js

  • Committer: Bazaar Package Importer
  • Author(s): Dominic Hargreaves, Dominic Hargreaves, Christian Perrier
  • Date: 2009-06-16 21:46:59 UTC
  • mfrom: (1.1.1 upstream)
  • Revision ID: james.westby@ubuntu.com-20090616214659-5ji9k1n3qyc2br3n
Tags: 3.8.4-1
[ Dominic Hargreaves ]
* Add missing comma in Depends (fixes FTBFS on etch)
* Update debconf translations: pt.po, ja.po, sv.po, it.po, cs.po, ru.po
  (Closes: #519885, #519922, #520603, #520759, #521199, #521926)
* Document preference for not using SQLite in production
  (Closes: #512750)

[ Christian Perrier ]
* Debconf templates and debian/control reviewed by the debian-l10n-
  english team as part of the Smith review project.
  (Closes: #522367, #520959)
* [Debconf translation updates]
  - Japanese. Closes: #522896
  - German. Closes: #520958
  - Portuguese. Closes: #523481
  - Galician. Closes: #524256
  - Galician. Closes: #524256
  - Spanish. Closes: #524449
  - Italian. Closes: #524715
  - Russian. Closes: #524894
  - Swedish. Closes: #525171
  - French. Closes: #525281

[ Dominic Hargreaves ]
* Don't tell dbconfig to comment out unused variables, since this
  breaks MySQL and Postgres database configuration (Closes: #523090)
* Update Standards-Version (no changes)
* Switch dependency on sysklogd to rsyslog (Closes: #526914)
* New upstream release; includes
  - Minor security fix (Closes: #533069)
  - Add missing Postgres index (Closes: #512653)
* Patch webmux.pl to provide a better error message when the wrong
  major version of RT is in @INC (for example in a mod_perl context).
  (Closes: #518692)
* Add some more example Exim 4 configuration (Closes: #238345)
* Don't apply database ACLs in databases managed by dbconfig-common.
* Remove unused ACL patch

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
1
/*
2
2
 * FCKeditor - The text editor for Internet - http://www.fckeditor.net
3
 
 * Copyright (C) 2003-2008 Frederico Caldeira Knabben
 
3
 * Copyright (C) 2003-2009 Frederico Caldeira Knabben
4
4
 *
5
5
 * == BEGIN LICENSE ==
6
6
 *
38
38
        var eParent ;
39
39
 
40
40
        // Save the current selection and scroll position.
41
 
        var oRange = new FCKDomRange( FCK.EditorWindow ) ;
42
 
        oRange.MoveToSelection() ;
43
 
        var oEditorScrollPos = FCKTools.GetScrollPosition( FCK.EditorWindow ) ;
 
41
        var oRange, oEditorScrollPos ;
 
42
        if ( FCK.EditMode == FCK_EDITMODE_WYSIWYG )
 
43
        {
 
44
                oRange = new FCKDomRange( FCK.EditorWindow ) ;
 
45
                oRange.MoveToSelection() ;
 
46
                oEditorScrollPos = FCKTools.GetScrollPosition( FCK.EditorWindow ) ;
 
47
        }
 
48
        else
 
49
        {
 
50
                var eTextarea = FCK.EditingArea.Textarea ;
 
51
                oRange = !FCKBrowserInfo.IsIE && [ eTextarea.selectionStart, eTextarea.selectionEnd ] ;
 
52
                oEditorScrollPos = [ eTextarea.scrollLeft, eTextarea.scrollTop ] ;
 
53
        }
44
54
 
45
55
        // No original style properties known? Go fullscreen.
46
56
        if ( !this.IsMaximized )
167
177
        FCK.Focus() ;
168
178
 
169
179
        // Restore the selection and scroll position of inside the document.
170
 
        oRange.Select() ;
171
 
        FCK.EditorWindow.scrollTo( oEditorScrollPos.X, oEditorScrollPos.Y ) ;
 
180
        if ( FCK.EditMode == FCK_EDITMODE_WYSIWYG )
 
181
        {
 
182
                oRange.Select() ;
 
183
                FCK.EditorWindow.scrollTo( oEditorScrollPos.X, oEditorScrollPos.Y ) ;
 
184
        }
 
185
        else
 
186
        {
 
187
                if ( !FCKBrowserInfo.IsIE )
 
188
                {
 
189
                        eTextarea.selectionStart = oRange[0] ;
 
190
                        eTextarea.selectionEnd = oRange[1] ;
 
191
                }
 
192
                eTextarea.scrollLeft = oEditorScrollPos[0] ;
 
193
                eTextarea.scrollTop = oEditorScrollPos[1] ;
 
194
        }
172
195
}
173
196
 
174
197
FCKFitWindow.prototype.GetState = function()