Fixes for remoteSearchDriver.js and related. Untested, probably doesn't work. Somewha...
authorTim Starling <tstarling@users.mediawiki.org>
Thu, 26 Nov 2009 03:10:01 +0000 (03:10 +0000)
committerTim Starling <tstarling@users.mediawiki.org>
Thu, 26 Nov 2009 03:10:01 +0000 (03:10 +0000)
commitf917ddc6336438fc4059dc1266669d14a7beaa84
tree22392a02073e587c0b3713194f487c19536d9c28
parentca8bfe2df81479fb150a83ee7b5f19240da8e2eb
Fixes for remoteSearchDriver.js and related. Untested, probably doesn't work. Somewhat less complete than r59278, I haven't done the comments and some bad variable names remain.

* Fixed multiple occurrences of </br> where <br/> was meant
* Made getSelection() into an accessor for this.caret_pos
* Split getTexboxSelection() into three accessors
* Merged init_interface_bindings() with initDialog()
* Split off showUploadForm_internal() from showUploadForm()
* Moved the upload check in showSearchTab() to its own function showCurrentTab()
* Moved the result display section of waitForResults() to a callback
* Removed the instance_name hack
* Fixed unanchored regex /res_/
* Split doMediaEdit() into showImageEditor() and showVideoEditor()
* Fixed unanchored regex /File:|Image:/
* Split updatePreviewText() into accessors getPreviewText() and getEmbedCode()
* Moved the doImportInterface() call from checkPrefixNameImport() to the checkImportResource() caller
* Use consistent spelling for "license"

Promoted anonymous functions to methods:
* getUploadForm_internal
* getResultHtml

Renamed functions:
  * getlicenseImgSet -> getLicenseIconHtml
  * setDispMode -> setDisplayMode
  * getParsedWikiText -> parse
  * init_modal -> createDialogContainer
  * init_interface_html -> initDialog
  * doUploadInteface -> showUploadTab
  * getUploadForm -> showUploadForm
  * runSearch -> showSearchTab
  * checkResultsDone -> waitForResults
  * drawOutputResults -> showResults
  * loadHQImg -> loadHighQualityImage
  * resourceEdit -> showResourceEditor
  * cancelClipEditCB -> onCancelClipEdit
  * checkRepoLocal -> isProviderLocal
  * checkForFile -> findFileInLocalWiki
  * checkImportResource -> isFileLocallyAvailable
  * checkPrefixNameImport -> isFileAlreadyImported
  * doImportInterface -> showImportUI
  * doImportAPI -> doApiImport
  * previewResource -> showPreview
  * getResourceObjet -> getResourceObject
js2/mwEmbed/libAddMedia/remoteSearchDriver.js
js2/mwEmbed/libAddMedia/searchLibs/archiveOrgSearch.js
js2/mwEmbed/libAddMedia/searchLibs/baseRemoteSearch.js
js2/mwEmbed/libAddMedia/searchLibs/flickrSearch.js
js2/mwEmbed/libAddMedia/searchLibs/metavidSearch.js
js2/mwEmbed/libAddMedia/simpleUploadForm.js
js2/mwEmbed/libSequencer/mvSequencer.js
js2/mwEmbed/mv_embed.js