summaryrefslogtreecommitdiff
path: root/lib/dijit/_editor/plugins/NewPage.js.uncompressed.js
diff options
context:
space:
mode:
authorBarak Korren <[email protected]>2013-04-02 20:38:07 +0300
committerBarak Korren <[email protected]>2013-04-02 20:38:07 +0300
commit58a2577d48790c79adfd44bcfd662c980ce6cfe4 (patch)
tree523d814ea0b7b6f617fe515b186099c6e83fed72 /lib/dijit/_editor/plugins/NewPage.js.uncompressed.js
parente470a273cf09562fb2f9c0c899002303f19c8d16 (diff)
parentcc332603431102a682feda22b9cf0093a29f0176 (diff)
Merge branch 'master' of https://github.com/gothfox/Tiny-Tiny-RSS.git
Diffstat (limited to 'lib/dijit/_editor/plugins/NewPage.js.uncompressed.js')
-rw-r--r--lib/dijit/_editor/plugins/NewPage.js.uncompressed.js77
1 files changed, 0 insertions, 77 deletions
diff --git a/lib/dijit/_editor/plugins/NewPage.js.uncompressed.js b/lib/dijit/_editor/plugins/NewPage.js.uncompressed.js
deleted file mode 100644
index 72b6f686a..000000000
--- a/lib/dijit/_editor/plugins/NewPage.js.uncompressed.js
+++ /dev/null
@@ -1,77 +0,0 @@
-define("dijit/_editor/plugins/NewPage", [
- "dojo/_base/declare", // declare
- "dojo/i18n", // i18n.getLocalization
- "dojo/_base/lang", // lang.hitch
- "../_Plugin",
- "../../form/Button",
- "dojo/i18n!../nls/commands"
-], function(declare, i18n, lang, _Plugin, Button){
-
-// module:
-// dijit/_editor/plugins/NewPage
-
-
-var NewPage = declare("dijit._editor.plugins.NewPage",_Plugin,{
- // summary:
- // This plugin provides a simple 'new page' capability. In other
- // words, set content to some default user defined string.
-
- // content: [public] String
- // The default content to insert into the editor as the new page.
- // The default is the `<br>` tag, a single blank line.
- content: "<br>",
-
- _initButton: function(){
- // summary:
- // Over-ride for creation of the Print button.
- var strings = i18n.getLocalization("dijit._editor", "commands"),
- editor = this.editor;
- this.button = new Button({
- label: strings["newPage"],
- ownerDocument: editor.ownerDocument,
- dir: editor.dir,
- lang: editor.lang,
- showLabel: false,
- iconClass: this.iconClassPrefix + " " + this.iconClassPrefix + "NewPage",
- tabIndex: "-1",
- onClick: lang.hitch(this, "_newPage")
- });
- },
-
- setEditor: function(/*dijit/Editor*/ editor){
- // summary:
- // Tell the plugin which Editor it is associated with.
- // editor: Object
- // The editor object to attach the newPage capability to.
- this.editor = editor;
- this._initButton();
- },
-
- updateState: function(){
- // summary:
- // Over-ride for button state control for disabled to work.
- this.button.set("disabled", this.get("disabled"));
- },
-
- _newPage: function(){
- // summary:
- // Function to set the content to blank.
- // tags:
- // private
- this.editor.beginEditing();
- this.editor.set("value", this.content);
- this.editor.endEditing();
- this.editor.focus();
- }
-});
-
-// Register this plugin.
-// For back-compat accept "newpage" (all lowercase) too, remove in 2.0
-_Plugin.registry["newPage"] = _Plugin.registry["newpage"] = function(args){
- return new NewPage({
- content: ("content" in args)?args.content:"<br>"
- });
-};
-
-return NewPage;
-});