Removes a ton of old unused legacy files
This commit is contained in:
@@ -27,15 +27,12 @@ namespace Umbraco.Tests.UI
|
||||
}
|
||||
|
||||
[TestCase(typeof(XsltTasks), DefaultApps.developer)]
|
||||
[TestCase(typeof(templateTasks), DefaultApps.settings)]
|
||||
[TestCase(typeof(StylesheetTasks), DefaultApps.settings)]
|
||||
[TestCase(typeof(stylesheetPropertyTasks), DefaultApps.settings)]
|
||||
[TestCase(typeof(ScriptTasks), DefaultApps.settings)]
|
||||
[TestCase(typeof(MemberGroupTasks), DefaultApps.member)]
|
||||
[TestCase(typeof(dictionaryTasks), DefaultApps.settings)]
|
||||
[TestCase(typeof(macroTasks), DefaultApps.developer)]
|
||||
[TestCase(typeof(languageTasks), DefaultApps.settings)]
|
||||
[TestCase(typeof(DLRScriptingTasks), DefaultApps.developer)]
|
||||
[TestCase(typeof(CreatedPackageTasks), DefaultApps.developer)]
|
||||
public void Check_Assigned_Apps_For_Tasks(Type taskType, DefaultApps app)
|
||||
{
|
||||
|
||||
@@ -1,69 +0,0 @@
|
||||
/**
|
||||
* editor_plugin_src.js
|
||||
*
|
||||
* Copyright 2012, Umbraco
|
||||
* Released under MIT License.
|
||||
*
|
||||
* License: http://opensource.org/licenses/mit-license.html
|
||||
*/
|
||||
|
||||
(function () {
|
||||
var Event = tinymce.dom.Event, each = tinymce.each, DOM = tinymce.DOM;
|
||||
|
||||
/**
|
||||
* This plugin modifies the standard TinyMCE context menu, with umbraco specific changes.
|
||||
*
|
||||
* @class tinymce.plugins.umbContextMenu
|
||||
*/
|
||||
tinymce.create('tinymce.plugins.UmbracoContextMenu', {
|
||||
/**
|
||||
* Initializes the plugin, this will be executed after the plugin has been created.
|
||||
* This call is done before the editor instance has finished it's initialization so use the onInit event
|
||||
* of the editor instance to intercept that event.
|
||||
*
|
||||
* @method init
|
||||
* @param {tinymce.Editor} ed Editor instance that the plugin is initialized in.
|
||||
* @param {string} url Absolute URL to where the plugin is located.
|
||||
*/
|
||||
init: function (ed) {
|
||||
if (ed.plugins.contextmenu) {
|
||||
|
||||
ed.plugins.contextmenu.onContextMenu.add(function (th, menu, event) {
|
||||
|
||||
var keys = UmbClientMgr.uiKeys();
|
||||
|
||||
$.each(menu.items, function (idx, el) {
|
||||
|
||||
switch (el.settings.cmd) {
|
||||
case "Cut":
|
||||
el.settings.title = keys['defaultdialogs_cut'];
|
||||
break;
|
||||
case "Copy":
|
||||
el.settings.title = keys['general_copy'];
|
||||
break;
|
||||
case "Paste":
|
||||
el.settings.title = keys['defaultdialogs_paste'];
|
||||
break;
|
||||
case "mceAdvLink":
|
||||
case "mceLink":
|
||||
el.settings.title = keys['defaultdialogs_insertlink'];
|
||||
break;
|
||||
case "UnLink":
|
||||
el.settings.title = keys['relatedlinks_removeLink'];
|
||||
break;
|
||||
case "mceImage":
|
||||
el.settings.title = keys['defaultdialogs_insertimage'];
|
||||
el.settings.cmd = "mceUmbimage";
|
||||
break;
|
||||
}
|
||||
|
||||
});
|
||||
|
||||
});
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
// Register plugin
|
||||
tinymce.PluginManager.add('umbracocontextmenu', tinymce.plugins.UmbracoContextMenu);
|
||||
})();
|
||||
-69
@@ -1,69 +0,0 @@
|
||||
/**
|
||||
* editor_plugin_src.js
|
||||
*
|
||||
* Copyright 2012, Umbraco
|
||||
* Released under MIT License.
|
||||
*
|
||||
* License: http://opensource.org/licenses/mit-license.html
|
||||
*/
|
||||
|
||||
(function () {
|
||||
var Event = tinymce.dom.Event, each = tinymce.each, DOM = tinymce.DOM;
|
||||
|
||||
/**
|
||||
* This plugin modifies the standard TinyMCE context menu, with umbraco specific changes.
|
||||
*
|
||||
* @class tinymce.plugins.umbContextMenu
|
||||
*/
|
||||
tinymce.create('tinymce.plugins.UmbracoContextMenu', {
|
||||
/**
|
||||
* Initializes the plugin, this will be executed after the plugin has been created.
|
||||
* This call is done before the editor instance has finished it's initialization so use the onInit event
|
||||
* of the editor instance to intercept that event.
|
||||
*
|
||||
* @method init
|
||||
* @param {tinymce.Editor} ed Editor instance that the plugin is initialized in.
|
||||
* @param {string} url Absolute URL to where the plugin is located.
|
||||
*/
|
||||
init: function (ed) {
|
||||
if (ed.plugins.contextmenu) {
|
||||
|
||||
ed.plugins.contextmenu.onContextMenu.add(function (th, menu, event) {
|
||||
|
||||
var keys = UmbClientMgr.uiKeys();
|
||||
|
||||
$.each(menu.items, function (idx, el) {
|
||||
|
||||
switch (el.settings.cmd) {
|
||||
case "Cut":
|
||||
el.settings.title = keys['defaultdialogs_cut'];
|
||||
break;
|
||||
case "Copy":
|
||||
el.settings.title = keys['general_copy'];
|
||||
break;
|
||||
case "Paste":
|
||||
el.settings.title = keys['defaultdialogs_paste'];
|
||||
break;
|
||||
case "mceAdvLink":
|
||||
case "mceLink":
|
||||
el.settings.title = keys['defaultdialogs_insertlink'];
|
||||
break;
|
||||
case "UnLink":
|
||||
el.settings.title = keys['relatedlinks_removeLink'];
|
||||
break;
|
||||
case "mceImage":
|
||||
el.settings.title = keys['defaultdialogs_insertimage'];
|
||||
el.settings.cmd = "mceUmbimage";
|
||||
break;
|
||||
}
|
||||
|
||||
});
|
||||
|
||||
});
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
// Register plugin
|
||||
tinymce.PluginManager.add('umbracocontextmenu', tinymce.plugins.UmbracoContextMenu);
|
||||
})();
|
||||
Binary file not shown.
|
Before Width: | Height: | Size: 87 B |
@@ -1,19 +0,0 @@
|
||||
tinyMCEPopup.requireLangPack();
|
||||
|
||||
var ExampleDialog = {
|
||||
init : function() {
|
||||
var f = document.forms[0];
|
||||
|
||||
// Get the selected contents as text and place it in the input
|
||||
f.someval.value = tinyMCEPopup.editor.selection.getContent({format : 'text'});
|
||||
f.somearg.value = tinyMCEPopup.getWindowArg('some_custom_arg');
|
||||
},
|
||||
|
||||
insert : function() {
|
||||
// Insert the contents from the input into the document
|
||||
tinyMCEPopup.editor.execCommand('mceInsertContent', false, document.forms[0].someval.value);
|
||||
tinyMCEPopup.close();
|
||||
}
|
||||
};
|
||||
|
||||
tinyMCEPopup.onInit.add(ExampleDialog.init, ExampleDialog);
|
||||
@@ -1,3 +0,0 @@
|
||||
tinyMCE.addI18n('en.example',{
|
||||
desc : 'This is just a template button'
|
||||
});
|
||||
@@ -1,3 +0,0 @@
|
||||
tinyMCE.addI18n('en.example_dlg',{
|
||||
title : 'This is just a example title'
|
||||
});
|
||||
@@ -1,3 +0,0 @@
|
||||
tinyMCE.addI18n('en_us.example',{
|
||||
desc : 'This is just a template button'
|
||||
});
|
||||
@@ -1,3 +0,0 @@
|
||||
tinyMCE.addI18n('en_us.example_dlg',{
|
||||
title : 'This is just a example title'
|
||||
});
|
||||
@@ -1,3 +0,0 @@
|
||||
tinyMCE.addI18n('it.example',{
|
||||
desc : 'Esempio di pulsante'
|
||||
});
|
||||
@@ -1,3 +0,0 @@
|
||||
tinyMCE.addI18n('it.example_dlg',{
|
||||
title : 'Esempio di titolo'
|
||||
});
|
||||
@@ -1,3 +0,0 @@
|
||||
tinyMCE.addI18n('ja.example',{
|
||||
desc : 'これはテンプレートボタンです'
|
||||
});
|
||||
@@ -1,3 +0,0 @@
|
||||
tinyMCE.addI18n('ja.example_dlg',{
|
||||
title : 'これは見出しの例です'
|
||||
});
|
||||
@@ -1,3 +0,0 @@
|
||||
tinyMCE.addI18n('ru.example',{
|
||||
desc : 'Это просто образец кнопки'
|
||||
});
|
||||
@@ -1,3 +0,0 @@
|
||||
tinyMCE.addI18n('ru.example_dlg',{
|
||||
title : 'Это просто пример заголовка'
|
||||
});
|
||||
@@ -1,3 +0,0 @@
|
||||
tinyMCE.addI18n('sv.example',{
|
||||
desc : 'Detta är bara en mallknapp'
|
||||
});
|
||||
@@ -1,3 +0,0 @@
|
||||
tinyMCE.addI18n('sv.example_dlg',{
|
||||
title : 'Detta är bara ett exempel på en titel'
|
||||
});
|
||||
@@ -1,3 +0,0 @@
|
||||
tinyMCE.addI18n('zh.example',{
|
||||
desc : '这是示例按钮'
|
||||
});
|
||||
@@ -1,3 +0,0 @@
|
||||
tinyMCE.addI18n('zh.example_dlg',{
|
||||
title : '这是示例标题'
|
||||
});
|
||||
@@ -1,182 +0,0 @@
|
||||
/**
|
||||
* $Id: editor_plugin_src.js 201 2007-02-12 15:56:56Z spocke $
|
||||
*
|
||||
* @author Moxiecode
|
||||
* @copyright Copyright © 2004-2008, Moxiecode Systems AB, All rights reserved.
|
||||
*/
|
||||
|
||||
(function () {
|
||||
// Load plugin specific language pack
|
||||
// tinymce.PluginManager.requireLangPack('umbraco');
|
||||
|
||||
tinymce.create('tinymce.plugins.umbracocss', {
|
||||
/**
|
||||
* Initializes the plugin, this will be executed after the plugin has been created.
|
||||
* This call is done before the editor instance has finished it's initialization so use the onInit event
|
||||
* of the editor instance to intercept that event.
|
||||
*
|
||||
* @param {tinymce.Editor} ed Editor instance that the plugin is initialized in.
|
||||
* @param {string} url Absolute URL to where the plugin is located.
|
||||
*/
|
||||
init: function (ed, url) {
|
||||
|
||||
this.editor = ed;
|
||||
|
||||
// Register the command so that it can be invoked by using tinyMCE.activeEditor.execCommand('mceExample');
|
||||
ed.addCommand('mceumbracosetstyle', function () {
|
||||
alert('blah');
|
||||
});
|
||||
|
||||
|
||||
// Add a node change handler, selects the button in the UI when a image is selected
|
||||
ed.onNodeChange.add(function (ed, cm, n) {
|
||||
var c = cm.get('umbracostyles');
|
||||
var formatSelected = false;
|
||||
|
||||
if (c) {
|
||||
// check for element
|
||||
var el = tinymce.DOM.getParent(n, ed.dom.isBlock);
|
||||
if (el) {
|
||||
for (var i = 0; i < c.items.length; i++) {
|
||||
if (c.items[i].value == el.nodeName.toLowerCase()) {
|
||||
c.select(el.nodeName.toLowerCase());
|
||||
formatSelected = true;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// check for class
|
||||
if (n.className != '') {
|
||||
if (c) {
|
||||
c.select('.' + n.className);
|
||||
}
|
||||
} else if (c && !formatSelected) {
|
||||
c.select(); // reset selector if no class or block elements
|
||||
}
|
||||
}
|
||||
|
||||
/* if (c = cm.get('styleselect')) {
|
||||
if (n.className) {
|
||||
t._importClasses();
|
||||
c.select(n.className);
|
||||
} else
|
||||
c.select();
|
||||
}
|
||||
|
||||
if (c = cm.get('formatselect')) {
|
||||
p = DOM.getParent(n, DOM.isBlock);
|
||||
|
||||
if (p)
|
||||
c.select(p.nodeName.toLowerCase());
|
||||
}
|
||||
*/
|
||||
});
|
||||
},
|
||||
|
||||
/**
|
||||
* Creates control instances based in the incomming name. This method is normally not
|
||||
* needed since the addButton method of the tinymce.Editor class is a more easy way of adding buttons
|
||||
* but you sometimes need to create more complex controls like listboxes, split buttons etc then this
|
||||
* method can be used to create those.
|
||||
*
|
||||
* @param {String} n Name of the control to create.
|
||||
* @param {tinymce.ControlManager} cm Control manager to use inorder to create new control.
|
||||
* @return {tinymce.ui.Control} New control instance or null if no control was created.
|
||||
*/
|
||||
createControl: function (n, cm) {
|
||||
|
||||
// add style dropdown
|
||||
if (n == 'umbracocss') {
|
||||
|
||||
var umbracoStyles = this.editor.getParam('theme_umbraco_styles').split(';');
|
||||
|
||||
var styles = cm.createListBox('umbracostyles', {
|
||||
title: this.editor.getLang('umbraco.style_select'),
|
||||
onselect: function (v) {
|
||||
if (v == '') {
|
||||
if (styles.selectedValue.indexOf('.') == 0) {
|
||||
// remove style
|
||||
var selectedStyle = styles.selectedValue;
|
||||
var styleObj = tinymce.activeEditor.formatter.get('umb' + selectedStyle.substring(1, selectedStyle.length));
|
||||
if (styleObj == undefined) {
|
||||
tinymce.activeEditor.formatter.register('umb' + selectedStyle.substring(1, selectedStyle.length), {
|
||||
inline: 'span',
|
||||
selector: '*',
|
||||
classes: selectedStyle.substring(1, selectedStyle.length)
|
||||
});
|
||||
}
|
||||
tinyMCE.activeEditor.formatter.remove('umb' + selectedStyle.substring(1, selectedStyle.length));
|
||||
|
||||
// tinymce.activeEditor.execCommand('mceSetStyleInfo', 0, { command: 'removeformat' });
|
||||
} else {
|
||||
// remove block element
|
||||
tinymce.activeEditor.execCommand('FormatBlock', false, 'p');
|
||||
}
|
||||
}
|
||||
else if (v.indexOf('.') != '0') {
|
||||
tinymce.activeEditor.execCommand('FormatBlock', false, v);
|
||||
} else {
|
||||
// use new formatting engine
|
||||
if (tinymce.activeEditor.formatter.get('umb' + v.substring(1, v.length)) == undefined) {
|
||||
tinymce.activeEditor.formatter.register('umb' + v.substring(1, v.length), {
|
||||
inline: 'span',
|
||||
selector: '*',
|
||||
classes: v.substring(1, v.length)
|
||||
});
|
||||
}
|
||||
var styleObj = tinymce.activeEditor.formatter.get('umb' + v.substring(1, v.length));
|
||||
tinyMCE.activeEditor.formatter.apply('umb' + v.substring(1, v.length));
|
||||
|
||||
// tinyMCE.activeEditor.execCommand('mceSetCSSClass', false, v.substring(1, v.length));
|
||||
|
||||
}
|
||||
return false;
|
||||
}
|
||||
});
|
||||
|
||||
// add styles
|
||||
for (var i = 0; i < umbracoStyles.length; i++) {
|
||||
if (umbracoStyles[i] != '') {
|
||||
var name = umbracoStyles[i].substring(0, umbracoStyles[i].indexOf("="));
|
||||
var alias = umbracoStyles[i].substring(umbracoStyles[i].indexOf("=") + 1, umbracoStyles[i].length);
|
||||
|
||||
if (alias.indexOf('.') < 0)
|
||||
alias = alias.toLowerCase();
|
||||
else if (alias.length > 1) {
|
||||
// register with new formatter engine (can't access from here so a hack in the set style above!)
|
||||
// tinyMCE.activeEditor.formatter.register('umb' + alias.substring(1, alias.length), {
|
||||
// classes: alias.substring(1, alias.length)
|
||||
// });
|
||||
}
|
||||
styles.add(name, alias);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
return styles;
|
||||
}
|
||||
|
||||
return null;
|
||||
},
|
||||
|
||||
|
||||
/**
|
||||
* Returns information about the plugin as a name/value array.
|
||||
* The current keys are longname, author, authorurl, infourl and version.
|
||||
*
|
||||
* @return {Object} Name/value array containing information about the plugin.
|
||||
*/
|
||||
getInfo: function () {
|
||||
return {
|
||||
longname: 'Umbraco CSS/Styling Plugin',
|
||||
author: 'Umbraco',
|
||||
authorurl: 'http://umbraco.org',
|
||||
infourl: 'http://wiki.moxiecode.com/index.php/TinyMCE:Plugins/example',
|
||||
version: "1.0"
|
||||
};
|
||||
}
|
||||
});
|
||||
|
||||
// Register plugin
|
||||
tinymce.PluginManager.add('umbracocss', tinymce.plugins.umbracocss);
|
||||
})();
|
||||
@@ -1,92 +0,0 @@
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
|
||||
<html xmlns="http://www.w3.org/1999/xhtml">
|
||||
<head>
|
||||
<title>{#embed_dlg.title}</title>
|
||||
<script type="text/javascript" src="../../../ui/jquery.js"></script>
|
||||
<script type="text/javascript" src="../../tiny_mce_popup.js"></script>
|
||||
<script type="text/javascript" src="js/dialog.js"></script>
|
||||
<script type="text/javascript" src="../../utils/mctabs.js"></script>
|
||||
<style>
|
||||
#previewContainer
|
||||
{
|
||||
height:195px;
|
||||
width:550px;
|
||||
overflow:auto;
|
||||
}
|
||||
#source
|
||||
{
|
||||
width:99%;
|
||||
height:270px;
|
||||
|
||||
}
|
||||
#url
|
||||
{
|
||||
width:400px;
|
||||
}
|
||||
.size
|
||||
{
|
||||
width:50px;
|
||||
}
|
||||
</style>
|
||||
</head>
|
||||
<body>
|
||||
|
||||
<form onsubmit="UmbracoEmbedDialog.insert();return false;" action="#">
|
||||
<div class="tabs" role="presentation">
|
||||
<ul>
|
||||
<li id="general_tab" class="current" aria-controls="general_panel"><span><a href="javascript:mcTabs.displayTab('general_tab','general_panel');" onmousedown="return false;">{#embed_dlg.general}</a></span></li>
|
||||
<li id="source_tab" aria-controls="source_panel"><span><a href="javascript:mcTabs.displayTab('source_tab','source_panel');" onmousedown="return false;">{#embed_dlg.source}</a></span></li>
|
||||
</ul>
|
||||
</div>
|
||||
<div class="panel_wrapper">
|
||||
<div id="general_panel" class="panel current">
|
||||
<fieldset>
|
||||
<legend>{#embed_dlg.general}</legend>
|
||||
<table role="presentation" border="0" cellpadding="4" cellspacing="0">
|
||||
<tr>
|
||||
<td><label for="media_type">{#embed_dlg.url}</label></td>
|
||||
<td>
|
||||
<input type="text" id="url" onChange="UmbracoEmbedDialog.showPreview()"/>
|
||||
</td>
|
||||
</tr>
|
||||
<tr id="dimensions">
|
||||
<td><label for="width">{#embed_dlg.size}</label></td>
|
||||
<td>
|
||||
<table role="presentation" border="0" cellpadding="0" cellspacing="0">
|
||||
<tr>
|
||||
<td><input type="text" id="width" name="width" value="500" class="size" onchange="UmbracoEmbedDialog.changeSize('width');" onfocus="UmbracoEmbedDialog.beforeResize();"/> x <input type="text" id="height" name="height" value="300" class="size" onchange="UmbracoEmbedDialog.changeSize('height');" onfocus="UmbracoEmbedDialog.beforeResize();" /></td>
|
||||
<td> <input id="constrain" type="checkbox" name="constrain" class="checkbox" checked="checked" /></td>
|
||||
<td><label id="constrainlabel" for="constrain">{#embed_dlg.constrain_proportions}</label></td>
|
||||
</tr>
|
||||
</table>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
|
||||
</fieldset>
|
||||
<fieldset>
|
||||
<legend>{#embed_dlg.preview}</legend>
|
||||
<div id="previewContainer">
|
||||
<div id="preview">
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</fieldset>
|
||||
</div>
|
||||
<div id="source_panel" class="panel">
|
||||
<fieldset>
|
||||
<legend>{#embed_dlg.source}</legend>
|
||||
<textarea id="source" onkeyup="UmbracoEmbedDialog.changeSource();" onchange="UmbracoEmbedDialog.updatePreviewFromSource();"></textarea>
|
||||
</fieldset>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<div class="mceActionPanel">
|
||||
<input type="button" id="insert" name="insert" value="{#insert}" onclick="UmbracoEmbedDialog.insert();" disabled="disabled"/>
|
||||
<input type="button" id="cancel" name="cancel" value="{#cancel}" onclick="tinyMCEPopup.close();" />
|
||||
</div>
|
||||
</form>
|
||||
|
||||
</body>
|
||||
</html>
|
||||
@@ -1 +0,0 @@
|
||||
(function(){tinymce.PluginManager.requireLangPack("example");tinymce.create("tinymce.plugins.ExamplePlugin",{init:function(a,b){a.addCommand("mceExample",function(){a.windowManager.open({file:b+"/dialog.htm",width:320+parseInt(a.getLang("example.delta_width",0)),height:120+parseInt(a.getLang("example.delta_height",0)),inline:1},{plugin_url:b,some_custom_arg:"custom arg"})});a.addButton("example",{title:"example.desc",cmd:"mceExample",image:b+"/img/example.gif"});a.onNodeChange.add(function(d,c,e){c.setActive("example",e.nodeName=="IMG")})},createControl:function(b,a){return null},getInfo:function(){return{longname:"Example plugin",author:"Some author",authorurl:"http://tinymce.moxiecode.com",infourl:"http://wiki.moxiecode.com/index.php/TinyMCE:Plugins/example",version:"1.0"}}});tinymce.PluginManager.add("example",tinymce.plugins.ExamplePlugin)})();
|
||||
@@ -1,84 +0,0 @@
|
||||
/**
|
||||
* editor_plugin_src.js
|
||||
*
|
||||
* Copyright 2009, Moxiecode Systems AB
|
||||
* Released under LGPL License.
|
||||
*
|
||||
* License: http://tinymce.moxiecode.com/license
|
||||
* Contributing: http://tinymce.moxiecode.com/contributing
|
||||
*/
|
||||
|
||||
(function() {
|
||||
// Load plugin specific language pack
|
||||
tinymce.PluginManager.requireLangPack('umbracoembed');
|
||||
|
||||
tinymce.create('tinymce.plugins.umbracoembed', {
|
||||
/**
|
||||
* Initializes the plugin, this will be executed after the plugin has been created.
|
||||
* This call is done before the editor instance has finished it's initialization so use the onInit event
|
||||
* of the editor instance to intercept that event.
|
||||
*
|
||||
* @param {tinymce.Editor} ed Editor instance that the plugin is initialized in.
|
||||
* @param {string} url Absolute URL to where the plugin is located.
|
||||
*/
|
||||
init : function(ed, url) {
|
||||
// Register the command so that it can be invoked by using tinyMCE.activeEditor.execCommand('mceExample');
|
||||
ed.addCommand('mceUmbracoEmbed', function() {
|
||||
ed.windowManager.open({
|
||||
file : url + '/dialog.htm',
|
||||
width : 600 + parseInt(ed.getLang('example.delta_width', 0)),
|
||||
height : 400 + parseInt(ed.getLang('example.delta_height', 0)),
|
||||
inline : 1
|
||||
}, {
|
||||
plugin_url : url, // Plugin absolute URL
|
||||
some_custom_arg : 'custom arg' // Custom argument
|
||||
});
|
||||
});
|
||||
|
||||
// Register example button
|
||||
ed.addButton('umbracoembed', {
|
||||
title : 'umbracoembed.desc',
|
||||
cmd : 'mceUmbracoEmbed',
|
||||
image : url + '/img/embed.gif'
|
||||
});
|
||||
|
||||
// Add a node change handler, selects the button in the UI when a image is selected
|
||||
/*ed.onNodeChange.add(function(ed, cm, n) {
|
||||
cm.setActive('example', n.nodeName == 'IMG');
|
||||
});*/
|
||||
},
|
||||
|
||||
/**
|
||||
* Creates control instances based in the incomming name. This method is normally not
|
||||
* needed since the addButton method of the tinymce.Editor class is a more easy way of adding buttons
|
||||
* but you sometimes need to create more complex controls like listboxes, split buttons etc then this
|
||||
* method can be used to create those.
|
||||
*
|
||||
* @param {String} n Name of the control to create.
|
||||
* @param {tinymce.ControlManager} cm Control manager to use inorder to create new control.
|
||||
* @return {tinymce.ui.Control} New control instance or null if no control was created.
|
||||
*/
|
||||
createControl : function(n, cm) {
|
||||
return null;
|
||||
},
|
||||
|
||||
/**
|
||||
* Returns information about the plugin as a name/value array.
|
||||
* The current keys are longname, author, authorurl, infourl and version.
|
||||
*
|
||||
* @return {Object} Name/value array containing information about the plugin.
|
||||
*/
|
||||
getInfo : function() {
|
||||
return {
|
||||
longname : 'Umbraco Embed',
|
||||
author : 'Tim Geyssens',
|
||||
authorurl : 'http://http://umbraco.com/',
|
||||
infourl : 'http://http://umbraco.com/',
|
||||
version : "1.0"
|
||||
};
|
||||
}
|
||||
});
|
||||
|
||||
// Register plugin
|
||||
tinymce.PluginManager.add('umbracoembed', tinymce.plugins.umbracoembed);
|
||||
})();
|
||||
Binary file not shown.
|
Before Width: | Height: | Size: 1.9 KiB |
Binary file not shown.
|
Before Width: | Height: | Size: 260 B |
Binary file not shown.
|
Before Width: | Height: | Size: 537 B |
@@ -1,90 +0,0 @@
|
||||
tinyMCEPopup.requireLangPack();
|
||||
|
||||
var UmbracoEmbedDialog = {
|
||||
insert: function () {
|
||||
// Insert the contents from the input into the document
|
||||
tinyMCEPopup.editor.execCommand('mceInsertContent', false, $('#source').val());
|
||||
tinyMCEPopup.close();
|
||||
},
|
||||
showPreview: function () {
|
||||
$('#insert').attr('disabled', 'disabled');
|
||||
|
||||
var url = $('#url').val();
|
||||
var width = $('#width').val(); ;
|
||||
var height = $('#height').val(); ;
|
||||
|
||||
$('#preview').html('<img src="img/ajax-loader.gif" alt="loading"/>');
|
||||
$('#source').val('');
|
||||
|
||||
$.ajax({
|
||||
type: 'POST',
|
||||
async: true,
|
||||
url: '../../../../base/EmbedMediaService/Embed/',
|
||||
data: { url: url, width: width, height: height },
|
||||
dataType: 'json',
|
||||
success: function (result) {
|
||||
switch (result.Status) {
|
||||
case 0:
|
||||
//not supported
|
||||
$('#preview').html('Not Supported');
|
||||
break;
|
||||
case 1:
|
||||
//error
|
||||
$('#preview').html('Error');
|
||||
break;
|
||||
case 2:
|
||||
$('#preview').html(result.Markup);
|
||||
$('#source').val(result.Markup);
|
||||
if (result.SupportsDimensions) {
|
||||
$('#dimensions').show();
|
||||
} else {
|
||||
$('#dimensions').hide();
|
||||
}
|
||||
$('#insert').removeAttr('disabled');
|
||||
break;
|
||||
}
|
||||
},
|
||||
error: function (xhr, ajaxOptions, thrownError) {
|
||||
$('#preview').html("Error");
|
||||
}
|
||||
});
|
||||
},
|
||||
beforeResize: function () {
|
||||
this.width = parseInt($('#width').val(), 10);
|
||||
this.height = parseInt($('#height').val(), 10);
|
||||
},
|
||||
changeSize: function (type) {
|
||||
var width, height, scale, size;
|
||||
|
||||
if ($('#constrain').is(':checked')) {
|
||||
width = parseInt($('#width').val(), 10);
|
||||
height = parseInt($('#height').val(), 10);
|
||||
if (type == 'width') {
|
||||
this.height = Math.round((width / this.width) * height);
|
||||
$('#height').val(this.height);
|
||||
} else {
|
||||
this.width = Math.round((height / this.height) * width);
|
||||
$('#width').val(this.width);
|
||||
}
|
||||
}
|
||||
if ($('#url').val() != '') {
|
||||
UmbracoEmbedDialog.showPreview();
|
||||
}
|
||||
},
|
||||
changeSource: function (type) {
|
||||
if ($('#source').val() != '') {
|
||||
$('#insert').removeAttr('disabled');
|
||||
}
|
||||
else {
|
||||
$('#insert').attr('disabled', 'disabled');
|
||||
}
|
||||
},
|
||||
updatePreviewFromSource: function (type) {
|
||||
var sourceVal = $('#source').val();
|
||||
|
||||
if (sourceVal != '') {
|
||||
$('#preview').html(sourceVal);
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
@@ -1,3 +0,0 @@
|
||||
tinyMCE.addI18n('da.umbracoembed', {
|
||||
desc: 'Inds\u00E6t ekstern mediefil'
|
||||
});
|
||||
@@ -1,9 +0,0 @@
|
||||
tinyMCE.addI18n('da.embed_dlg', {
|
||||
title: 'Inds\u00E6t ekstern mediefil',
|
||||
general: 'Generelt',
|
||||
url: 'Url:',
|
||||
size: 'Dimensioner:',
|
||||
constrain_proportions: 'Bevar proportioner',
|
||||
preview: 'Vis',
|
||||
source: 'Vis kilde'
|
||||
});
|
||||
@@ -1,10 +0,0 @@
|
||||
tinyMCE.addI18n('de.embed_dlg', {
|
||||
title: 'Medien von Drittanbietern einbetten',
|
||||
general: 'Allgemein',
|
||||
url: 'Url:',
|
||||
size: 'Abmessungen:',
|
||||
constrain_proportions: 'Proportionen beibehalten',
|
||||
preview: 'Vorschau',
|
||||
source: 'Quellcode'
|
||||
|
||||
});
|
||||
@@ -1,10 +0,0 @@
|
||||
tinyMCE.addI18n('de.embed_dlg', {
|
||||
title: 'Medien von Drittanbietern einbetten',
|
||||
general: 'Allgemein',
|
||||
url: 'Url:',
|
||||
size: 'Abmessungen:',
|
||||
constrain_proportions: 'Proportionen beibehalten',
|
||||
preview: 'Vorschau',
|
||||
source: 'Quellcode'
|
||||
|
||||
});
|
||||
@@ -1,3 +0,0 @@
|
||||
tinyMCE.addI18n('en.umbracoembed', {
|
||||
desc: 'Embed third party media'
|
||||
});
|
||||
@@ -1,10 +0,0 @@
|
||||
tinyMCE.addI18n('en.embed_dlg', {
|
||||
title: 'Embed third party media',
|
||||
general: 'General',
|
||||
url: 'Url:',
|
||||
size: 'Size:',
|
||||
constrain_proportions: 'Constrain',
|
||||
preview: 'Preview',
|
||||
source: 'Source'
|
||||
|
||||
});
|
||||
@@ -1,3 +0,0 @@
|
||||
tinyMCE.addI18n('en_us.umbracoembed', {
|
||||
desc: 'Embed third party media'
|
||||
});
|
||||
@@ -1,10 +0,0 @@
|
||||
tinyMCE.addI18n('en_us.embed_dlg', {
|
||||
title: 'Embed third party media',
|
||||
general: 'General',
|
||||
url: 'Url:',
|
||||
size: 'Size:',
|
||||
constrain_proportions: 'Constrain',
|
||||
preview: 'Preview',
|
||||
source: 'Source'
|
||||
|
||||
});
|
||||
@@ -1,9 +0,0 @@
|
||||
tinyMCE.addI18n('en.embed_dlg', {
|
||||
title: 'Integra media di terze parti',
|
||||
general: 'Generale',
|
||||
url: 'Url:',
|
||||
size: 'Dimensione:',
|
||||
constrain_proportions: 'Vincolo',
|
||||
preview: 'Anteprima',
|
||||
source: 'Sorgente'
|
||||
});
|
||||
@@ -1,9 +0,0 @@
|
||||
tinyMCE.addI18n('it.embed_dlg', {
|
||||
title: 'Integra media di terze parti',
|
||||
general: 'Generale',
|
||||
url: 'Url:',
|
||||
size: 'Dimensione:',
|
||||
constrain_proportions: 'Vincolo',
|
||||
preview: 'Anteprima',
|
||||
source: 'Sorgente'
|
||||
});
|
||||
@@ -1,10 +0,0 @@
|
||||
tinyMCE.addI18n('ja.embed_dlg', {
|
||||
title: 'サードパーティメディアの埋め込み',
|
||||
general: '一般',
|
||||
url: 'Url:',
|
||||
size: 'サイズ:',
|
||||
constrain_proportions: '制約',
|
||||
preview: 'プレビュー',
|
||||
source: 'ソース'
|
||||
|
||||
});
|
||||
@@ -1,10 +0,0 @@
|
||||
tinyMCE.addI18n('ja.embed_dlg', {
|
||||
title: サードパーティメディアの埋め込み',
|
||||
general: '一般',
|
||||
url: 'Url:',
|
||||
size: 'サイズ:',
|
||||
constrain_proportions: '制約',
|
||||
preview: 'プレビュー',
|
||||
source: 'ソース'
|
||||
|
||||
});
|
||||
@@ -1,10 +0,0 @@
|
||||
tinyMCE.addI18n('ru.embed_dlg', {
|
||||
title: 'Вставить внеший элемент медиа',
|
||||
general: 'Общее',
|
||||
url: 'Ссылка:',
|
||||
size: 'Размер:',
|
||||
constrain_proportions: 'Сохранять пропорции',
|
||||
preview: 'Просмотр',
|
||||
source: 'Источник'
|
||||
|
||||
});
|
||||
@@ -1,10 +0,0 @@
|
||||
tinyMCE.addI18n('ru.embed_dlg', {
|
||||
title: 'Вставить внеший элемент медиа',
|
||||
general: 'Общее',
|
||||
url: 'Ссылка:',
|
||||
size: 'Размер:',
|
||||
constrain_proportions: 'Сохранять пропорции',
|
||||
preview: 'Просмотр',
|
||||
source: 'Источник'
|
||||
|
||||
});
|
||||
@@ -1,10 +0,0 @@
|
||||
tinyMCE.addI18n('sv.embed_dlg', {
|
||||
title: 'Bädda in tredjeparts media',
|
||||
general: 'Generell',
|
||||
url: 'Url:',
|
||||
size: 'Storlek:',
|
||||
constrain_proportions: 'Bibehåll proportioner',
|
||||
preview: 'Förhandsgranska',
|
||||
source: 'Källa'
|
||||
|
||||
});
|
||||
@@ -1,10 +0,0 @@
|
||||
tinyMCE.addI18n('sv.embed_dlg', {
|
||||
title: 'Bädda in tredjeparts media',
|
||||
general: 'Generell',
|
||||
url: 'Url:',
|
||||
size: 'Storlek:',
|
||||
constrain_proportions: 'Bibehåll proportioner',
|
||||
preview: 'Förhandsgranska',
|
||||
source: 'Källa'
|
||||
|
||||
});
|
||||
@@ -1,10 +0,0 @@
|
||||
tinyMCE.addI18n('zh.embed_dlg', {
|
||||
title: '嵌入第三方媒体',
|
||||
general: '普通',
|
||||
url: '链接:',
|
||||
size: '尺寸:',
|
||||
constrain_proportions: '约束比例',
|
||||
preview: '预览',
|
||||
source: '源'
|
||||
|
||||
});
|
||||
@@ -1,9 +0,0 @@
|
||||
tinyMCE.addI18n('zh.embed_dlg', {
|
||||
title: '嵌入第三方媒体',
|
||||
general: '普通',
|
||||
url: '链接:',
|
||||
size: '尺寸:',
|
||||
constrain_proportions: '约束比例',
|
||||
preview: '预览',
|
||||
source: '源'
|
||||
});
|
||||
@@ -1,52 +0,0 @@
|
||||
/**
|
||||
* $Id: editor_plugin_src.js 677 2008-03-07 13:52:41Z spocke $
|
||||
*
|
||||
* @author Moxiecode
|
||||
* @copyright Copyright © 2004-2008, Moxiecode Systems AB, All rights reserved.
|
||||
*/
|
||||
|
||||
(function() {
|
||||
// tinymce.PluginManager.requireLangPack('umbraco');
|
||||
|
||||
tinymce.create('tinymce.plugins.UmbracoImagePlugin', {
|
||||
init: function(ed, url) {
|
||||
// Register commands
|
||||
ed.addCommand('mceUmbimage', function() {
|
||||
// Internal image object like a flash placeholder
|
||||
if (ed.dom.getAttrib(ed.selection.getNode(), 'class').indexOf('mceItem') != -1)
|
||||
return;
|
||||
|
||||
ed.windowManager.open({
|
||||
/* UMBRACO SPECIFIC: Load Umbraco modal window */
|
||||
file: tinyMCE.activeEditor.getParam('umbraco_path') + '/plugins/tinymce3/insertImage.aspx',
|
||||
width: 575 + ed.getLang('umbracoimg.delta_width', 0),
|
||||
height: 505 + ed.getLang('umbracoimg.delta_height', 0),
|
||||
inline: 1
|
||||
}, {
|
||||
plugin_url: url
|
||||
});
|
||||
});
|
||||
|
||||
// Register buttons
|
||||
ed.addButton('image', {
|
||||
title: 'advimage.image_desc',
|
||||
cmd: 'mceUmbimage'
|
||||
});
|
||||
|
||||
},
|
||||
|
||||
getInfo: function() {
|
||||
return {
|
||||
longname: 'Umbraco image dialog',
|
||||
author: 'Umbraco',
|
||||
authorurl: 'http://umbraco.org',
|
||||
infourl: 'http://umbraco.org',
|
||||
version: "1.0"
|
||||
};
|
||||
}
|
||||
});
|
||||
|
||||
// Register plugin
|
||||
tinymce.PluginManager.add('umbracoimg', tinymce.plugins.UmbracoImagePlugin);
|
||||
|
||||
})();
|
||||
@@ -1,332 +0,0 @@
|
||||
var ImageDialog = {
|
||||
preInit: function() {
|
||||
var url;
|
||||
|
||||
tinyMCEPopup.requireLangPack();
|
||||
|
||||
if (url = tinyMCEPopup.getParam("external_image_list_url"))
|
||||
document.write('<script language="javascript" type="text/javascript" src="' + tinyMCEPopup.editor.documentBaseURI.toAbsolute(url) + '"></script>');
|
||||
},
|
||||
|
||||
init: function(ed) {
|
||||
var f = document.forms[0], nl = f.elements, ed = tinyMCEPopup.editor, dom = ed.dom, n = ed.selection.getNode();
|
||||
|
||||
tinyMCEPopup.resizeToInnerSize();
|
||||
|
||||
if (n.nodeName == 'IMG') {
|
||||
nl.src.value = dom.getAttrib(n, 'src');
|
||||
nl.width.value = dom.getAttrib(n, 'width');
|
||||
nl.height.value = dom.getAttrib(n, 'height');
|
||||
nl.alt.value = dom.getAttrib(n, 'alt');
|
||||
nl.orgHeight.value = dom.getAttrib(n, 'rel').split(",")[1];
|
||||
nl.orgWidth.value = dom.getAttrib(n, 'rel').split(",")[0];
|
||||
|
||||
}
|
||||
|
||||
// If option enabled default contrain proportions to checked
|
||||
if ((ed.getParam("advimage_constrain_proportions", true)) && f.constrain)
|
||||
f.constrain.checked = true;
|
||||
|
||||
this.changeAppearance();
|
||||
this.showPreviewImage(nl.src.value, 1);
|
||||
},
|
||||
|
||||
insert: function(file, title) {
|
||||
var ed = tinyMCEPopup.editor, t = this, f = document.forms[0];
|
||||
|
||||
if (f.src.value === '') {
|
||||
if (ed.selection.getNode().nodeName == 'IMG') {
|
||||
ed.dom.remove(ed.selection.getNode());
|
||||
ed.execCommand('mceRepaint');
|
||||
}
|
||||
|
||||
tinyMCEPopup.close();
|
||||
return;
|
||||
}
|
||||
|
||||
if (tinyMCEPopup.getParam("accessibility_warnings", 1)) {
|
||||
if (!f.alt.value) {
|
||||
tinyMCEPopup.confirm(tinyMCEPopup.getLang('advimage_dlg.missing_alt'), function(s) {
|
||||
if (s)
|
||||
t.insertAndClose();
|
||||
});
|
||||
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
||||
t.insertAndClose();
|
||||
},
|
||||
|
||||
insertAndClose: function() {
|
||||
var ed = tinyMCEPopup.editor, f = document.forms[0], nl = f.elements, v, args = {}, el;
|
||||
|
||||
tinyMCEPopup.restoreSelection();
|
||||
|
||||
// Fixes crash in Safari
|
||||
if (tinymce.isWebKit)
|
||||
ed.getWin().focus();
|
||||
|
||||
if (!ed.settings.inline_styles) {
|
||||
args = {
|
||||
vspace: nl.vspace.value,
|
||||
hspace: nl.hspace.value,
|
||||
border: nl.border.value,
|
||||
align: getSelectValue(f, 'align')
|
||||
};
|
||||
} else {
|
||||
// Remove deprecated values
|
||||
args = {
|
||||
vspace: '',
|
||||
hspace: '',
|
||||
border: '',
|
||||
align: ''
|
||||
};
|
||||
}
|
||||
|
||||
tinymce.extend(args, {
|
||||
src: nl.src.value,
|
||||
width: nl.width.value,
|
||||
height: nl.height.value,
|
||||
alt: nl.alt.value,
|
||||
title: nl.alt.value,
|
||||
rel: nl.orgWidth.value + ',' + nl.orgHeight.value
|
||||
});
|
||||
|
||||
args.onmouseover = args.onmouseout = '';
|
||||
|
||||
el = ed.selection.getNode();
|
||||
|
||||
if (el && el.nodeName == 'IMG') {
|
||||
ed.dom.setAttribs(el, args);
|
||||
} else {
|
||||
ed.execCommand('mceInsertContent', false, '<img id="__mce_tmp" />', { skip_undo: 1 });
|
||||
ed.dom.setAttribs('__mce_tmp', args);
|
||||
ed.dom.setAttrib('__mce_tmp', 'id', '');
|
||||
ed.undoManager.add();
|
||||
}
|
||||
|
||||
tinyMCEPopup.close();
|
||||
},
|
||||
|
||||
getAttrib: function(e, at) {
|
||||
var ed = tinyMCEPopup.editor, dom = ed.dom, v, v2;
|
||||
|
||||
if (ed.settings.inline_styles) {
|
||||
switch (at) {
|
||||
case 'align':
|
||||
if (v = dom.getStyle(e, 'float'))
|
||||
return v;
|
||||
|
||||
if (v = dom.getStyle(e, 'vertical-align'))
|
||||
return v;
|
||||
|
||||
break;
|
||||
|
||||
case 'hspace':
|
||||
v = dom.getStyle(e, 'margin-left')
|
||||
v2 = dom.getStyle(e, 'margin-right');
|
||||
|
||||
if (v && v == v2)
|
||||
return parseInt(v.replace(/[^0-9]/g, ''));
|
||||
|
||||
break;
|
||||
|
||||
case 'vspace':
|
||||
v = dom.getStyle(e, 'margin-top')
|
||||
v2 = dom.getStyle(e, 'margin-bottom');
|
||||
if (v && v == v2)
|
||||
return parseInt(v.replace(/[^0-9]/g, ''));
|
||||
|
||||
break;
|
||||
|
||||
case 'border':
|
||||
v = 0;
|
||||
|
||||
tinymce.each(['top', 'right', 'bottom', 'left'], function(sv) {
|
||||
sv = dom.getStyle(e, 'border-' + sv + '-width');
|
||||
|
||||
// False or not the same as prev
|
||||
if (!sv || (sv != v && v !== 0)) {
|
||||
v = 0;
|
||||
return false;
|
||||
}
|
||||
|
||||
if (sv)
|
||||
v = sv;
|
||||
});
|
||||
|
||||
if (v)
|
||||
return parseInt(v.replace(/[^0-9]/g, ''));
|
||||
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
if (v = dom.getAttrib(e, at))
|
||||
return v;
|
||||
|
||||
return '';
|
||||
},
|
||||
|
||||
setSwapImage: function(st) {
|
||||
var f = document.forms[0];
|
||||
|
||||
f.onmousemovecheck.checked = st;
|
||||
setBrowserDisabled('overbrowser', !st);
|
||||
setBrowserDisabled('outbrowser', !st);
|
||||
|
||||
if (f.over_list)
|
||||
f.over_list.disabled = !st;
|
||||
|
||||
if (f.out_list)
|
||||
f.out_list.disabled = !st;
|
||||
|
||||
f.onmouseoversrc.disabled = !st;
|
||||
f.onmouseoutsrc.disabled = !st;
|
||||
},
|
||||
|
||||
resetImageData: function() {
|
||||
var f = document.forms[0];
|
||||
|
||||
f.elements.width.value = f.elements.height.value = '';
|
||||
},
|
||||
|
||||
updateImageData: function(img, st) {
|
||||
var f = document.forms[0];
|
||||
|
||||
if (!st) {
|
||||
f.elements.width.value = img.width;
|
||||
f.elements.height.value = img.height;
|
||||
}
|
||||
|
||||
this.preloadImg = img;
|
||||
},
|
||||
|
||||
changeAppearance: function() {
|
||||
var ed = tinyMCEPopup.editor, f = document.forms[0], img = document.getElementById('alignSampleImg');
|
||||
|
||||
if (img) {
|
||||
if (ed.getParam('inline_styles')) {
|
||||
ed.dom.setAttrib(img, 'style', f.style.value);
|
||||
} else {
|
||||
img.align = f.align.value;
|
||||
img.border = f.border.value;
|
||||
img.hspace = f.hspace.value;
|
||||
img.vspace = f.vspace.value;
|
||||
}
|
||||
}
|
||||
},
|
||||
|
||||
changeHeight: function() {
|
||||
var f = document.forms[0], tp, t = this;
|
||||
alert(t.preloadImg);
|
||||
|
||||
if (!f.constrain.checked || !t.preloadImg) {
|
||||
return;
|
||||
}
|
||||
|
||||
if (f.width.value == '' || f.height.value == '')
|
||||
return;
|
||||
|
||||
tp = (parseInt(f.width.value) / parseInt(t.preloadImg.width)) * t.preloadImg.height;
|
||||
f.height.value = tp.toFixed(0);
|
||||
},
|
||||
|
||||
changeWidth: function() {
|
||||
var f = document.forms[0], tp, t = this;
|
||||
|
||||
if (!f.constrain.checked || !t.preloadImg) {
|
||||
return;
|
||||
}
|
||||
|
||||
if (f.width.value == '' || f.height.value == '')
|
||||
return;
|
||||
|
||||
tp = (parseInt(f.height.value) / parseInt(t.preloadImg.height)) * t.preloadImg.width;
|
||||
f.width.value = tp.toFixed(0);
|
||||
},
|
||||
|
||||
updateStyle: function(ty) {
|
||||
var dom = tinyMCEPopup.dom, st, v, f = document.forms[0], img = dom.create('img', { style: dom.get('style').value });
|
||||
|
||||
if (tinyMCEPopup.editor.settings.inline_styles) {
|
||||
// Handle align
|
||||
if (ty == 'align') {
|
||||
dom.setStyle(img, 'float', '');
|
||||
dom.setStyle(img, 'vertical-align', '');
|
||||
|
||||
v = getSelectValue(f, 'align');
|
||||
if (v) {
|
||||
if (v == 'left' || v == 'right')
|
||||
dom.setStyle(img, 'float', v);
|
||||
else
|
||||
img.style.verticalAlign = v;
|
||||
}
|
||||
}
|
||||
|
||||
// Handle border
|
||||
if (ty == 'border') {
|
||||
dom.setStyle(img, 'border', '');
|
||||
|
||||
v = f.border.value;
|
||||
if (v || v == '0') {
|
||||
if (v == '0')
|
||||
img.style.border = '0';
|
||||
else
|
||||
img.style.border = v + 'px solid black';
|
||||
}
|
||||
}
|
||||
|
||||
// Handle hspace
|
||||
if (ty == 'hspace') {
|
||||
dom.setStyle(img, 'marginLeft', '');
|
||||
dom.setStyle(img, 'marginRight', '');
|
||||
|
||||
v = f.hspace.value;
|
||||
if (v) {
|
||||
img.style.marginLeft = v + 'px';
|
||||
img.style.marginRight = v + 'px';
|
||||
}
|
||||
}
|
||||
|
||||
// Handle vspace
|
||||
if (ty == 'vspace') {
|
||||
dom.setStyle(img, 'marginTop', '');
|
||||
dom.setStyle(img, 'marginBottom', '');
|
||||
|
||||
v = f.vspace.value;
|
||||
if (v) {
|
||||
img.style.marginTop = v + 'px';
|
||||
img.style.marginBottom = v + 'px';
|
||||
}
|
||||
}
|
||||
|
||||
// Merge
|
||||
dom.get('style').value = dom.serializeStyle(dom.parseStyle(img.style.cssText));
|
||||
}
|
||||
},
|
||||
|
||||
changeMouseMove: function() {
|
||||
},
|
||||
|
||||
showPreviewImage: function(u, st) {
|
||||
if (!u) {
|
||||
tinyMCEPopup.dom.setHTML('prev', '');
|
||||
return;
|
||||
}
|
||||
|
||||
if (!st && tinyMCEPopup.getParam("advimage_update_dimensions_onchange", true))
|
||||
this.resetImageData();
|
||||
|
||||
u = tinyMCEPopup.editor.documentBaseURI.toAbsolute(u);
|
||||
|
||||
if (!st)
|
||||
tinyMCEPopup.dom.setHTML('prev', '<img id="previewImg" src="' + u + '" border="0" onload="ImageDialog.updateImageData(this);" onerror="ImageDialog.resetImageData();" />');
|
||||
else
|
||||
tinyMCEPopup.dom.setHTML('prev', '<img id="previewImg" src="' + u + '" border="0" onload="ImageDialog.updateImageData(this, 1);" />');
|
||||
}
|
||||
};
|
||||
|
||||
ImageDialog.preInit();
|
||||
tinyMCEPopup.onInit.add(ImageDialog.init, ImageDialog);
|
||||
@@ -1,43 +0,0 @@
|
||||
tinyMCE.addI18n('en.umbimage_dlg', {
|
||||
tab_general: 'General',
|
||||
tab_appearance: 'Appearance',
|
||||
tab_advanced: 'Advanced',
|
||||
general: 'General',
|
||||
title: 'Title',
|
||||
preview: 'Preview',
|
||||
constrain_proportions: 'Constrain proportions',
|
||||
langdir: 'Language direction',
|
||||
langcode: 'Language code',
|
||||
long_desc: 'Long description link',
|
||||
style: 'Style',
|
||||
classes: 'Classes',
|
||||
ltr: 'Left to right',
|
||||
rtl: 'Right to left',
|
||||
id: 'Id',
|
||||
map: 'Image map',
|
||||
swap_image: 'Swap image',
|
||||
alt_image: 'Alternative image',
|
||||
mouseover: 'for mouse over',
|
||||
mouseout: 'for mouse out',
|
||||
misc: 'Miscellaneous',
|
||||
example_img: 'Appearance preview image',
|
||||
missing_alt: 'Are you sure you want to continue without including an Image Description? Without it the image may not be accessible to some users with disabilities, or to those using a text browser, or browsing the Web with images turned off.',
|
||||
dialog_title: 'Insert/edit image',
|
||||
src: 'Image URL',
|
||||
alt: 'Image description',
|
||||
list: 'Image list',
|
||||
border: 'Border',
|
||||
dimensions: 'Dimensions',
|
||||
vspace: 'Vertical space',
|
||||
hspace: 'Horizontal space',
|
||||
align: 'Alignment',
|
||||
align_baseline: 'Baseline',
|
||||
align_top: 'Top',
|
||||
align_middle: 'Middle',
|
||||
align_bottom: 'Bottom',
|
||||
align_texttop: 'Text top',
|
||||
align_textbottom: 'Text bottom',
|
||||
align_left: 'Left',
|
||||
align_right: 'Right',
|
||||
image_list: 'Image list'
|
||||
});
|
||||
@@ -1,43 +0,0 @@
|
||||
tinyMCE.addI18n('en_us.umbimage_dlg', {
|
||||
tab_general: 'General',
|
||||
tab_appearance: 'Appearance',
|
||||
tab_advanced: 'Advanced',
|
||||
general: 'General',
|
||||
title: 'Title',
|
||||
preview: 'Preview',
|
||||
constrain_proportions: 'Constrain proportions',
|
||||
langdir: 'Language direction',
|
||||
langcode: 'Language code',
|
||||
long_desc: 'Long description link',
|
||||
style: 'Style',
|
||||
classes: 'Classes',
|
||||
ltr: 'Left to right',
|
||||
rtl: 'Right to left',
|
||||
id: 'Id',
|
||||
map: 'Image map',
|
||||
swap_image: 'Swap image',
|
||||
alt_image: 'Alternative image',
|
||||
mouseover: 'for mouse over',
|
||||
mouseout: 'for mouse out',
|
||||
misc: 'Miscellaneous',
|
||||
example_img: 'Appearance preview image',
|
||||
missing_alt: 'Are you sure you want to continue without including an Image Description? Without it the image may not be accessible to some users with disabilities, or to those using a text browser, or browsing the Web with images turned off.',
|
||||
dialog_title: 'Insert/edit image',
|
||||
src: 'Image URL',
|
||||
alt: 'Image description',
|
||||
list: 'Image list',
|
||||
border: 'Border',
|
||||
dimensions: 'Dimensions',
|
||||
vspace: 'Vertical space',
|
||||
hspace: 'Horizontal space',
|
||||
align: 'Alignment',
|
||||
align_baseline: 'Baseline',
|
||||
align_top: 'Top',
|
||||
align_middle: 'Middle',
|
||||
align_bottom: 'Bottom',
|
||||
align_texttop: 'Text top',
|
||||
align_textbottom: 'Text bottom',
|
||||
align_left: 'Left',
|
||||
align_right: 'Right',
|
||||
image_list: 'Image list'
|
||||
});
|
||||
@@ -1,43 +0,0 @@
|
||||
tinyMCE.addI18n('he.umbimage_dlg', {
|
||||
tab_general: 'General',
|
||||
tab_appearance: 'Appearance',
|
||||
tab_advanced: 'Advanced',
|
||||
general: 'General',
|
||||
title: 'Title',
|
||||
preview: 'Preview',
|
||||
constrain_proportions: 'Constrain proportions',
|
||||
langdir: 'Language direction',
|
||||
langcode: 'Language code',
|
||||
long_desc: 'Long description link',
|
||||
style: 'Style',
|
||||
classes: 'Classes',
|
||||
ltr: 'Left to right',
|
||||
rtl: 'Right to left',
|
||||
id: 'Id',
|
||||
map: 'Image map',
|
||||
swap_image: 'Swap image',
|
||||
alt_image: 'Alternative image',
|
||||
mouseover: 'for mouse over',
|
||||
mouseout: 'for mouse out',
|
||||
misc: 'Miscellaneous',
|
||||
example_img: 'Appearance preview image',
|
||||
missing_alt: 'Are you sure you want to continue without including an Image Description? Without it the image may not be accessible to some users with disabilities, or to those using a text browser, or browsing the Web with images turned off.',
|
||||
dialog_title: 'Insert/edit image',
|
||||
src: 'Image URL',
|
||||
alt: 'Image description',
|
||||
list: 'Image list',
|
||||
border: 'Border',
|
||||
dimensions: 'Dimensions',
|
||||
vspace: 'Vertical space',
|
||||
hspace: 'Horizontal space',
|
||||
align: 'Alignment',
|
||||
align_baseline: 'Baseline',
|
||||
align_top: 'Top',
|
||||
align_middle: 'Middle',
|
||||
align_bottom: 'Bottom',
|
||||
align_texttop: 'Text top',
|
||||
align_textbottom: 'Text bottom',
|
||||
align_left: 'Left',
|
||||
align_right: 'Right',
|
||||
image_list: 'Image list'
|
||||
});
|
||||
@@ -1,43 +0,0 @@
|
||||
tinyMCE.addI18n('it.umbimage_dlg', {
|
||||
tab_general: 'Generale',
|
||||
tab_appearance: 'Aspetto',
|
||||
tab_advanced: 'Avanzate',
|
||||
general: 'Generale',
|
||||
title: 'Titolo',
|
||||
preview: 'Anteprima',
|
||||
constrain_proportions: 'Vincola proporzioni',
|
||||
langdir: 'Direzione lingua',
|
||||
langcode: 'Codice lingua',
|
||||
long_desc: 'Descrizione lunga del collegamento',
|
||||
style: 'Stile',
|
||||
classes: 'Classi',
|
||||
ltr: 'Da sinistra a destra',
|
||||
rtl: 'Da destra a sinistra',
|
||||
id: 'Id',
|
||||
map: 'Image map',
|
||||
swap_image: 'Swap immagine',
|
||||
alt_image: 'Testo alternativo',
|
||||
mouseover: 'Mouse over',
|
||||
mouseout: 'Mouse out',
|
||||
misc: 'Varie',
|
||||
example_img: 'Aspetto anteprima immagine',
|
||||
missing_alt: 'Sei sicuro di voler continuare senza includere una Descrizione dell'immagine? Se non lo fai l'immagine potrebbe risultare non accessibile per gli utenti con disabilit\u00E0, o per chi utilizza un browser di testo, o per chi naviga senza immagini.',
|
||||
dialog_title: 'Inserisci/Modifica immagine',
|
||||
src: 'URL immagine',
|
||||
alt: 'Descrizione immagine',
|
||||
list: 'Immagine lista',
|
||||
border: 'Bordo',
|
||||
dimensions: 'Dimensioni',
|
||||
vspace: 'Spaziatura verticale',
|
||||
hspace: 'Spaziatura orizzontale',
|
||||
align: 'Allineamento',
|
||||
align_baseline: 'Baseline',
|
||||
align_top: 'Top',
|
||||
align_middle: 'Middle',
|
||||
align_bottom: 'Bottom',
|
||||
align_texttop: 'Testo superiore',
|
||||
align_textbottom: 'Testo inferiore',
|
||||
align_left: 'Sinistra',
|
||||
align_right: 'Destra',
|
||||
image_list: 'Immagine lista'
|
||||
});
|
||||
@@ -1,43 +0,0 @@
|
||||
tinyMCE.addI18n('ja.umbimage_dlg', {
|
||||
tab_general: '一般',
|
||||
tab_appearance: '表示',
|
||||
tab_advanced: '高度な設定',
|
||||
general: '一般',
|
||||
title: 'タイトル',
|
||||
preview: 'プレビュー',
|
||||
constrain_proportions: '縦横比の維持',
|
||||
langdir: '文章の方向',
|
||||
langcode: '言語コード',
|
||||
long_desc: '詳細な説明のリンク',
|
||||
style: 'スタイル',
|
||||
classes: 'クラス',
|
||||
ltr: '左から右',
|
||||
rtl: '右から左',
|
||||
id: 'Id',
|
||||
map: 'イメージマップ',
|
||||
swap_image: '画像の入れ替え',
|
||||
alt_image: '別の画像',
|
||||
mouseover: 'マウスカーソルがかかる時',
|
||||
mouseout: 'マウスカーソルが外れる時',
|
||||
misc: 'その他',
|
||||
example_img: '画像のプレビューの様子',
|
||||
missing_alt: '画像の説明を含めずに続けますか?画像の説明がないと目の不自由な方、テキスト表示だけのブラウザを使用している方、画像の表示を止めてる方がアクセスできないかもしれません。',
|
||||
dialog_title: '画像の挿入/編集',
|
||||
src: '画像のURL',
|
||||
alt: '画像の説明',
|
||||
list: '画像の一覧',
|
||||
border: '枠線',
|
||||
dimensions: '寸法',
|
||||
vspace: '上下の余白',
|
||||
hspace: '左右の余白',
|
||||
align: '配置',
|
||||
align_baseline: 'ベースライン揃え',
|
||||
align_top: '上揃え',
|
||||
align_middle: '中央揃え',
|
||||
align_bottom: '下揃え',
|
||||
align_texttop: 'テキストの上端揃え',
|
||||
align_textbottom: 'テキストの下端揃え',
|
||||
align_left: '左寄せ',
|
||||
align_right: '右寄せ',
|
||||
image_list: '画像の一覧'
|
||||
});
|
||||
@@ -1,43 +0,0 @@
|
||||
tinyMCE.addI18n('ru.umbimage_dlg', {
|
||||
tab_general: 'Общее',
|
||||
tab_appearance: 'Вид',
|
||||
tab_advanced: 'Дополнительно',
|
||||
general: 'Общие свойства',
|
||||
title: 'Заголовок',
|
||||
preview: 'Предпросмотр',
|
||||
constrain_proportions: 'Сохранять пропорции',
|
||||
langdir: 'Направление языка',
|
||||
langcode: 'Код языка',
|
||||
long_desc: 'Ссылка на длинное описание',
|
||||
style: 'Стиль',
|
||||
classes: 'Классы CSS',
|
||||
ltr: 'Слева напрапво',
|
||||
rtl: 'Справа налево',
|
||||
id: 'Id',
|
||||
map: 'Карта',
|
||||
swap_image: 'Замена',
|
||||
alt_image: 'Альтернатива',
|
||||
mouseover: 'при заходе мыши',
|
||||
mouseout: 'при выходе мыши',
|
||||
misc: 'Разное',
|
||||
example_img: 'Пример внешнего вида',
|
||||
missing_alt: 'Вы уверены, что хотите продолжить без указания описания изображения? Без описания изображение может оказаться недоступным некоторым категориям пользователей с ограниченными возможностями, или использующим текстовый браузер, а также пользователям, отключившим показ изображений.',
|
||||
dialog_title: 'Вставить/изменить изображение',
|
||||
src: 'URL изображения',
|
||||
alt: 'Описание изображения',
|
||||
list: 'Список',
|
||||
border: 'Рамка',
|
||||
dimensions: 'Размеры',
|
||||
vspace: 'Отступ по вертикали',
|
||||
hspace: 'Отступ по горизонтали',
|
||||
align: 'Выравнивание',
|
||||
align_baseline: 'По базовой линии',
|
||||
align_top: 'По верху',
|
||||
align_middle: 'По центру',
|
||||
align_bottom: 'По низу',
|
||||
align_texttop: 'По верху текста',
|
||||
align_textbottom: 'По низу текста',
|
||||
align_left: 'По левому краю',
|
||||
align_right: 'По правому краю',
|
||||
image_list: 'Список изображений'
|
||||
});
|
||||
@@ -1,43 +0,0 @@
|
||||
tinyMCE.addI18n('sv.umbimage_dlg', {
|
||||
tab_general: 'Generellt',
|
||||
tab_appearance: 'Utseende',
|
||||
tab_advanced: 'Avancerat',
|
||||
general: 'Generellt',
|
||||
title: 'Titel',
|
||||
preview: 'Förhandsgranska',
|
||||
constrain_proportions: 'Bibehåll proportioner',
|
||||
langdir: 'Språkdirektion',
|
||||
langcode: 'Språkkod',
|
||||
long_desc: 'Lång länkbeskrivning',
|
||||
style: 'Stil',
|
||||
classes: 'Klasser',
|
||||
ltr: 'Vänster till höger',
|
||||
rtl: 'höger till vänster',
|
||||
id: 'Id',
|
||||
map: 'Bildkarta',
|
||||
swap_image: 'Byt bild',
|
||||
alt_image: 'Alternativ bild',
|
||||
mouseover: 'För musen över',
|
||||
mouseout: 'för musen utanför',
|
||||
misc: 'Blandat',
|
||||
example_img: 'Visning av bildförhandsgranskning',
|
||||
missing_alt: 'Are you sure you want to continue without including an Image Description? Without it the image may not be accessible to some users with disabilities, or to those using a text browser, or browsing the Web with images turned off.',
|
||||
dialog_title: 'Infoga/redigera bild',
|
||||
src: 'Bild URL',
|
||||
alt: 'Bildbeskrivning',
|
||||
list: 'Bildlista',
|
||||
border: 'Ram',
|
||||
dimensions: 'Dimensioner',
|
||||
vspace: 'Vertikalt avstånd',
|
||||
hspace: 'Horisontellt avstånd',
|
||||
align: 'Position',
|
||||
align_baseline: 'Baslinje',
|
||||
align_top: 'Toppen',
|
||||
align_middle: 'Mitten',
|
||||
align_bottom: 'Botten',
|
||||
align_texttop: 'Text topp',
|
||||
align_textbottom: 'Text botten',
|
||||
align_left: 'Vänster',
|
||||
align_right: 'Höger',
|
||||
image_list: 'Bildlista'
|
||||
});
|
||||
@@ -1,43 +0,0 @@
|
||||
tinyMCE.addI18n('zh.umbimage_dlg', {
|
||||
tab_general: '普通',
|
||||
tab_appearance: '外观',
|
||||
tab_advanced: '高级',
|
||||
general: '普通',
|
||||
title: '标题',
|
||||
preview: '预览',
|
||||
constrain_proportions: '约束比例',
|
||||
langdir: '语言书写方向',
|
||||
langcode: '语言代码',
|
||||
long_desc: '长原文链接',
|
||||
style: '样式',
|
||||
classes: '类',
|
||||
ltr: '从左到右',
|
||||
rtl: '从右到左',
|
||||
id: 'Id',
|
||||
map: '图片热区',
|
||||
swap_image: '交换图片',
|
||||
alt_image: '替代图片',
|
||||
mouseover: '鼠标移入',
|
||||
mouseout: '鼠标移出',
|
||||
misc: '其它',
|
||||
example_img: '样图外观',
|
||||
missing_alt: '你确定不要图片替代文字吗?替代文字可以在图片无法显示时显示。',
|
||||
dialog_title: '插入/编辑图片',
|
||||
src: '图片URL',
|
||||
alt: '图片描述',
|
||||
list: '图片列表',
|
||||
border: '边框',
|
||||
dimensions: '尺寸',
|
||||
vspace: '垂直间距',
|
||||
hspace: '水平间距',
|
||||
align: '对齐',
|
||||
align_baseline: '对齐底线',
|
||||
align_top: '顶部对齐',
|
||||
align_middle: '中间对齐',
|
||||
align_bottom: '底部对齐',
|
||||
align_texttop: '对齐文字顶部',
|
||||
align_textbottom: '对齐文字底部',
|
||||
align_left: '左对齐',
|
||||
align_right: '右对齐',
|
||||
image_list: '图片列表'
|
||||
});
|
||||
@@ -1,5 +0,0 @@
|
||||
/**
|
||||
* This file is intentionally left empty
|
||||
* For reference, see: http://issues.umbraco.org/issue/U4-9724
|
||||
* The logic for the umbracoLink plugin now lives in ~/Umbraco/Js/umbraco.services.js
|
||||
*/
|
||||
@@ -1,27 +0,0 @@
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
|
||||
<html xmlns="http://www.w3.org/1999/xhtml">
|
||||
<head>
|
||||
<title>{#example_dlg.title}</title>
|
||||
<script type="text/javascript" src="../../tiny_mce_popup.js"></script>
|
||||
<script type="text/javascript" src="js/dialog.js"></script>
|
||||
</head>
|
||||
<body>
|
||||
|
||||
<form onsubmit="ExampleDialog.insert();return false;" action="#">
|
||||
<p>Here is a example dialog.</p>
|
||||
<p>Selected text: <input id="someval" name="someval" type="text" class="text" /></p>
|
||||
<p>Custom arg: <input id="somearg" name="somearg" type="text" class="text" /></p>
|
||||
|
||||
<div class="mceActionPanel">
|
||||
<div style="float: left">
|
||||
<input type="button" id="insert" name="insert" value="{#insert}" onclick="ExampleDialog.insert();" />
|
||||
</div>
|
||||
|
||||
<div style="float: right">
|
||||
<input type="button" id="cancel" name="cancel" value="{#cancel}" onclick="tinyMCEPopup.close();" />
|
||||
</div>
|
||||
</div>
|
||||
</form>
|
||||
|
||||
</body>
|
||||
</html>
|
||||
@@ -1,145 +0,0 @@
|
||||
/**
|
||||
* $Id: editor_plugin_src.js 201 2007-02-12 15:56:56Z spocke $
|
||||
*
|
||||
* @author Moxiecode
|
||||
* @copyright Copyright © 2004-2008, Moxiecode Systems AB, All rights reserved.
|
||||
*/
|
||||
|
||||
(function() {
|
||||
// Load plugin specific language pack
|
||||
// tinymce.PluginManager.requireLangPack('umbraco');
|
||||
|
||||
tinymce.create('tinymce.plugins.umbracomacro', {
|
||||
/**
|
||||
* Initializes the plugin, this will be executed after the plugin has been created.
|
||||
* This call is done before the editor instance has finished it's initialization so use the onInit event
|
||||
* of the editor instance to intercept that event.
|
||||
*
|
||||
* @param {tinymce.Editor} ed Editor instance that the plugin is initialized in.
|
||||
* @param {string} url Absolute URL to where the plugin is located.
|
||||
*/
|
||||
init: function(ed, url) {
|
||||
var t = this;
|
||||
|
||||
// Register the command so that it can be invoked by using tinyMCE.activeEditor.execCommand('mceExample');
|
||||
ed.addCommand('mceumbracomacro', function() {
|
||||
var se = ed.selection;
|
||||
|
||||
var urlParams = "";
|
||||
var el = se.getNode();
|
||||
|
||||
// ie selector bug
|
||||
if (!ed.dom.hasClass(el, 'umbMacroHolder')) {
|
||||
el = ed.dom.getParent(el, 'div.umbMacroHolder');
|
||||
}
|
||||
|
||||
var attrString = "";
|
||||
if (ed.dom.hasClass(el, 'umbMacroHolder')) {
|
||||
for (var i = 0; i < el.attributes.length; i++) {
|
||||
attrName = el.attributes[i].nodeName.toLowerCase();
|
||||
if (attrName != "mce_serialized") {
|
||||
if (el.attributes[i].nodeValue && (attrName != 'ismacro' && attrName != 'style' && attrName != 'contenteditable')) {
|
||||
attrString += el.attributes[i].nodeName + '=' + escape(t._utf8_encode(el.attributes[i].nodeValue)) + '&'; //.replace(/#/g, "%23").replace(/\</g, "%3C").replace(/\>/g, "%3E").replace(/\"/g, "%22") + '&';
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// vi trunkerer strengen ved at fjerne et evt. overskydende amp;
|
||||
if (attrString.length > 0)
|
||||
attrString = attrString.substr(0, attrString.length - 1);
|
||||
|
||||
urlParams = "&" + attrString;
|
||||
} else {
|
||||
urlParams = '&umbPageId=' + tinyMCE.activeEditor.getParam('theme_umbraco_pageId') + '&umbVersionId=' + tinyMCE.activeEditor.getParam('theme_umbraco_versionId');
|
||||
}
|
||||
|
||||
ed.windowManager.open({
|
||||
file: tinyMCE.activeEditor.getParam('umbraco_path') + '/plugins/tinymce3/insertMacro.aspx?editor=trueurl' + urlParams,
|
||||
width: 480 + parseInt(ed.getLang('umbracomacro.delta_width', 0)),
|
||||
height: 470 + parseInt(ed.getLang('umbracomacro.delta_height', 0)),
|
||||
inline: 1
|
||||
}, {
|
||||
plugin_url: url // Plugin absolute URL
|
||||
});
|
||||
});
|
||||
|
||||
// Register example button
|
||||
ed.addButton('umbracomacro', {
|
||||
title: 'umbracomacro.desc',
|
||||
cmd: 'mceumbracomacro',
|
||||
image: url + '/img/insMacro.gif'
|
||||
});
|
||||
|
||||
// Add a node change handler, test if we're editing a macro
|
||||
ed.onNodeChange.addToTop(function(ed, cm, n) {
|
||||
|
||||
var macroElement = ed.dom.getParent(ed.selection.getStart(), 'div.umbMacroHolder');
|
||||
|
||||
// mark button if it's a macro
|
||||
cm.setActive('umbracomacro', macroElement && ed.dom.hasClass(macroElement, 'umbMacroHolder'));
|
||||
|
||||
});
|
||||
},
|
||||
|
||||
_utf8_encode: function(string) {
|
||||
string = string.replace(/\r\n/g, "\n");
|
||||
var utftext = "";
|
||||
|
||||
for (var n = 0; n < string.length; n++) {
|
||||
|
||||
var c = string.charCodeAt(n);
|
||||
|
||||
if (c < 128) {
|
||||
utftext += String.fromCharCode(c);
|
||||
}
|
||||
else if ((c > 127) && (c < 2048)) {
|
||||
utftext += String.fromCharCode((c >> 6) | 192);
|
||||
utftext += String.fromCharCode((c & 63) | 128);
|
||||
}
|
||||
else {
|
||||
utftext += String.fromCharCode((c >> 12) | 224);
|
||||
utftext += String.fromCharCode(((c >> 6) & 63) | 128);
|
||||
utftext += String.fromCharCode((c & 63) | 128);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
return utftext;
|
||||
},
|
||||
|
||||
/**
|
||||
* Creates control instances based in the incomming name. This method is normally not
|
||||
* needed since the addButton method of the tinymce.Editor class is a more easy way of adding buttons
|
||||
* but you sometimes need to create more complex controls like listboxes, split buttons etc then this
|
||||
* method can be used to create those.
|
||||
*
|
||||
* @param {String} n Name of the control to create.
|
||||
* @param {tinymce.ControlManager} cm Control manager to use inorder to create new control.
|
||||
* @return {tinymce.ui.Control} New control instance or null if no control was created.
|
||||
*/
|
||||
createControl: function(n, cm) {
|
||||
return null;
|
||||
},
|
||||
|
||||
|
||||
/**
|
||||
* Returns information about the plugin as a name/value array.
|
||||
* The current keys are longname, author, authorurl, infourl and version.
|
||||
*
|
||||
* @return {Object} Name/value array containing information about the plugin.
|
||||
*/
|
||||
getInfo: function() {
|
||||
return {
|
||||
longname: 'Umbraco Macro Insertion Plugin',
|
||||
author: 'Umbraco',
|
||||
authorurl: 'http://umbraco.org',
|
||||
infourl: 'http://umbraco.org/redir/tinymcePlugins',
|
||||
version: "1.0"
|
||||
};
|
||||
}
|
||||
});
|
||||
|
||||
// Register plugin
|
||||
tinymce.PluginManager.add('umbracomacro', tinymce.plugins.umbracomacro);
|
||||
})();
|
||||
Binary file not shown.
|
Before Width: | Height: | Size: 603 B |
@@ -1,19 +0,0 @@
|
||||
tinyMCEPopup.requireLangPack();
|
||||
|
||||
var ExampleDialog = {
|
||||
init : function() {
|
||||
var f = document.forms[0];
|
||||
|
||||
// Get the selected contents as text and place it in the input
|
||||
f.someval.value = tinyMCEPopup.editor.selection.getContent({format : 'text'});
|
||||
f.somearg.value = tinyMCEPopup.getWindowArg('some_custom_arg');
|
||||
},
|
||||
|
||||
insert : function() {
|
||||
// Insert the contents from the input into the document
|
||||
tinyMCEPopup.editor.execCommand('mceInsertContent', false, document.forms[0].someval.value);
|
||||
tinyMCEPopup.close();
|
||||
}
|
||||
};
|
||||
|
||||
tinyMCEPopup.onInit.add(ExampleDialog.init, ExampleDialog);
|
||||
@@ -1,3 +0,0 @@
|
||||
tinyMCE.addI18n('en.umbracomacro',{
|
||||
desc : 'Insert macro'
|
||||
});
|
||||
@@ -1,3 +0,0 @@
|
||||
tinyMCE.addI18n('en.example_dlg',{
|
||||
title : 'This is just a example title'
|
||||
});
|
||||
@@ -1,3 +0,0 @@
|
||||
tinyMCE.addI18n('en_us.umbracomacro',{
|
||||
desc : 'Insert macro'
|
||||
});
|
||||
@@ -1,3 +0,0 @@
|
||||
tinyMCE.addI18n('en_us.example_dlg',{
|
||||
title : 'This is just a example title'
|
||||
});
|
||||
@@ -1,3 +0,0 @@
|
||||
tinyMCE.addI18n('he.umbracomacro',{
|
||||
desc : 'הוסף מאקרו'
|
||||
});
|
||||
@@ -1,3 +0,0 @@
|
||||
tinyMCE.addI18n('he.example_dlg',{
|
||||
title : 'This is just a example title'
|
||||
});
|
||||
@@ -1,3 +0,0 @@
|
||||
tinyMCE.addI18n('ja.umbracomacro',{
|
||||
desc : 'マクロの挿入'
|
||||
});
|
||||
@@ -1,3 +0,0 @@
|
||||
tinyMCE.addI18n('ja.example_dlg',{
|
||||
title : 'これはタイトルの例です'
|
||||
});
|
||||
@@ -1,3 +0,0 @@
|
||||
tinyMCE.addI18n('ru.umbracomacro',{
|
||||
desc : 'Вставить макрос'
|
||||
});
|
||||
@@ -1,3 +0,0 @@
|
||||
tinyMCE.addI18n('ru.example_dlg',{
|
||||
title : 'Это просто пример заголовка'
|
||||
});
|
||||
@@ -1,3 +0,0 @@
|
||||
tinyMCE.addI18n('sv.umbracomacro',{
|
||||
desc : 'Infoga makro'
|
||||
});
|
||||
@@ -1,3 +0,0 @@
|
||||
tinyMCE.addI18n('sv.example_dlg',{
|
||||
title : 'Detta är bar ett exempel på en titel'
|
||||
});
|
||||
@@ -1,3 +0,0 @@
|
||||
tinyMCE.addI18n('zh.umbracomacro',{
|
||||
desc : '插入宏'
|
||||
});
|
||||
@@ -1,3 +0,0 @@
|
||||
tinyMCE.addI18n('zh.example_dlg',{
|
||||
title : '这是示例标题'
|
||||
});
|
||||
@@ -1,53 +0,0 @@
|
||||
/**
|
||||
* editor_plugin_src.js
|
||||
*
|
||||
* Copyright 2012, Umbraco
|
||||
* Released under MIT License.
|
||||
*
|
||||
* License: http://opensource.org/licenses/mit-license.html
|
||||
*/
|
||||
|
||||
(function () {
|
||||
var Event = tinymce.dom.Event, each = tinymce.each, DOM = tinymce.DOM;
|
||||
|
||||
/**
|
||||
* This plugin modifies the standard TinyMCE paste, with umbraco specific changes.
|
||||
*
|
||||
* @class tinymce.plugins.umbContextMenu
|
||||
*/
|
||||
tinymce.create('tinymce.plugins.UmbracoPaste', {
|
||||
/**
|
||||
* Initializes the plugin, this will be executed after the plugin has been created.
|
||||
* This call is done before the editor instance has finished it's initialization so use the onInit event
|
||||
* of the editor instance to intercept that event.
|
||||
*
|
||||
* @method init
|
||||
* @param {tinymce.Editor} ed Editor instance that the plugin is initialized in.
|
||||
* @param {string} url Absolute URL to where the plugin is located.
|
||||
*/
|
||||
init: function (ed) {
|
||||
var t = this;
|
||||
|
||||
ed.plugins.paste.onPreProcess.add(function (pl, o) {
|
||||
|
||||
var ed = this.editor, h = o.content;
|
||||
|
||||
var umbracoAllowedStyles = ed.getParam('theme_umbraco_styles');
|
||||
for (var i = 1; i < 7; i++) {
|
||||
if (umbracoAllowedStyles.indexOf("h" + i) == -1) {
|
||||
h = h.replace(new RegExp('<h' + i + '[^>]*', 'gi'), '<p><strong');
|
||||
h = h.replace(new RegExp('</h' + i + '>', 'gi'), '</strong></p>');
|
||||
}
|
||||
}
|
||||
|
||||
o.content = h;
|
||||
|
||||
});
|
||||
|
||||
}
|
||||
|
||||
});
|
||||
|
||||
// Register plugin
|
||||
tinymce.PluginManager.add('umbracopaste', tinymce.plugins.UmbracoPaste);
|
||||
})();
|
||||
@@ -1,43 +0,0 @@
|
||||
|
||||
(function () {
|
||||
tinymce.create('tinymce.plugins.Umbracoshortcut', {
|
||||
init: function (ed, url) {
|
||||
var t = this;
|
||||
var ctrlPressed = false;
|
||||
|
||||
t.editor = ed;
|
||||
|
||||
ed.onKeyDown.add(function (ed, e) {
|
||||
if (e.keyCode == 17)
|
||||
ctrlPressed = true;
|
||||
|
||||
if (ctrlPressed && e.keyCode == 83) {
|
||||
jQuery(document).trigger("UMBRACO_TINYMCE_SAVE", e);
|
||||
ctrlPressed = false;
|
||||
tinymce.dom.Event.cancel(e);
|
||||
return false;
|
||||
}
|
||||
});
|
||||
|
||||
ed.onKeyUp.add(function (ed, e) {
|
||||
if (e.keyCode == 17)
|
||||
ctrlPressed = false;
|
||||
});
|
||||
},
|
||||
|
||||
getInfo: function () {
|
||||
return {
|
||||
longname: 'Umbraco Save short cut key',
|
||||
author: 'Umbraco HQ',
|
||||
authorurl: 'http://umbraco.com',
|
||||
infourl: 'http://our.umbraco.org',
|
||||
version: "1.0"
|
||||
};
|
||||
}
|
||||
|
||||
// Private methods
|
||||
});
|
||||
|
||||
// Register plugin
|
||||
tinymce.PluginManager.add('umbracoshortcut', tinymce.plugins.Umbracoshortcut);
|
||||
})();
|
||||
+1
-1
@@ -358,7 +358,7 @@ angular.module("umbraco.directives")
|
||||
var unsubscribe = scope.$on("formSubmitting", function () {
|
||||
//TODO: Here we should parse out the macro rendered content so we can save on a lot of bytes in data xfer
|
||||
// we do parse it out on the server side but would be nice to do that on the client side before as well.
|
||||
scope.value = tinyMceEditor.getContent();
|
||||
scope.value = tinyMceEditor ? tinyMceEditor.getContent() : null;
|
||||
});
|
||||
|
||||
//when the element is disposed we need to unsubscribe!
|
||||
|
||||
@@ -365,7 +365,7 @@ angular.module("umbraco")
|
||||
var unsubscribe = $scope.$on("formSubmitting", function () {
|
||||
//TODO: Here we should parse out the macro rendered content so we can save on a lot of bytes in data xfer
|
||||
// we do parse it out on the server side but would be nice to do that on the client side before as well.
|
||||
$scope.model.value = tinyMceEditor.getContent();
|
||||
$scope.model.value = tinyMceEditor ? tinyMceEditor.getContent() : null;
|
||||
});
|
||||
|
||||
//when the element is disposed we need to unsubscribe!
|
||||
|
||||
@@ -124,9 +124,6 @@
|
||||
<HintPath>..\packages\ClientDependency-Mvc5.1.8.0.0\lib\net45\ClientDependency.Core.Mvc.dll</HintPath>
|
||||
<Private>True</Private>
|
||||
</Reference>
|
||||
<Reference Include="CookComputing.XmlRpcV2, Version=2.5.0.0, Culture=neutral, PublicKeyToken=a7d6e17aa302004d, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\xmlrpcnet.2.5.0\lib\net20\CookComputing.XmlRpcV2.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="dotless.Core, Version=1.5.2.0, Culture=neutral, PublicKeyToken=96b446c9e63eae34, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\dotless.1.5.2\lib\dotless.Core.dll</HintPath>
|
||||
</Reference>
|
||||
@@ -367,20 +364,6 @@
|
||||
<DesignTimeSharedInput>True</DesignTimeSharedInput>
|
||||
<DependentUpon>Settings.settings</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="Umbraco\Controls\Images\ImageViewer.ascx.cs">
|
||||
<DependentUpon>ImageViewer.ascx</DependentUpon>
|
||||
<SubType>ASPXCodeBehind</SubType>
|
||||
</Compile>
|
||||
<Compile Include="Umbraco\Controls\Images\ImageViewer.ascx.designer.cs">
|
||||
<DependentUpon>ImageViewer.ascx</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="Umbraco\Controls\PasswordChanger.ascx.cs">
|
||||
<DependentUpon>passwordChanger.ascx</DependentUpon>
|
||||
<SubType>ASPXCodeBehind</SubType>
|
||||
</Compile>
|
||||
<Compile Include="Umbraco\Controls\PasswordChanger.ascx.designer.cs">
|
||||
<DependentUpon>passwordChanger.ascx</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="Umbraco\Create.aspx.cs">
|
||||
<DependentUpon>create.aspx</DependentUpon>
|
||||
<SubType>ASPXCodeBehind</SubType>
|
||||
@@ -388,48 +371,13 @@
|
||||
<Compile Include="Umbraco\Create.aspx.designer.cs">
|
||||
<DependentUpon>create.aspx</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="Umbraco\Create\DlrScripting.ascx.cs">
|
||||
<DependentUpon>DlrScripting.ascx</DependentUpon>
|
||||
<SubType>ASPXCodeBehind</SubType>
|
||||
</Compile>
|
||||
<Compile Include="Umbraco\Create\DlrScripting.ascx.designer.cs">
|
||||
<DependentUpon>DlrScripting.ascx</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="Umbraco\Create\PartialView.ascx.cs">
|
||||
<DependentUpon>PartialView.ascx</DependentUpon>
|
||||
<SubType>ASPXCodeBehind</SubType>
|
||||
</Compile>
|
||||
<Compile Include="Umbraco\Create\PartialView.ascx.designer.cs">
|
||||
<DependentUpon>PartialView.ascx</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="Umbraco\Create\PartialViewMacro.ascx.cs">
|
||||
<DependentUpon>PartialViewMacro.ascx</DependentUpon>
|
||||
<SubType>ASPXCodeBehind</SubType>
|
||||
</Compile>
|
||||
<Compile Include="Umbraco\Create\PartialViewMacro.ascx.designer.cs">
|
||||
<DependentUpon>PartialViewMacro.ascx</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="Umbraco\Create\xslt.ascx.cs">
|
||||
<DependentUpon>xslt.ascx</DependentUpon>
|
||||
<SubType>ASPXCodeBehind</SubType>
|
||||
</Compile>
|
||||
<Compile Include="Umbraco\Create\User.ascx.cs">
|
||||
<DependentUpon>User.ascx</DependentUpon>
|
||||
<SubType>ASPXCodeBehind</SubType>
|
||||
</Compile>
|
||||
<Compile Include="Umbraco\Create\xslt.ascx.designer.cs">
|
||||
<DependentUpon>xslt.ascx</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="Umbraco\Create\User.ascx.designer.cs">
|
||||
<DependentUpon>User.ascx</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="Umbraco\Dashboard\ExamineManagement.ascx.cs">
|
||||
<DependentUpon>ExamineManagement.ascx</DependentUpon>
|
||||
<SubType>ASPXCodeBehind</SubType>
|
||||
</Compile>
|
||||
<Compile Include="Umbraco\Dashboard\ExamineManagement.ascx.designer.cs">
|
||||
<DependentUpon>ExamineManagement.ascx</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="Umbraco\Dashboard\UserControlProxy.aspx.cs">
|
||||
<DependentUpon>UserControlProxy.aspx</DependentUpon>
|
||||
<SubType>ASPXCodeBehind</SubType>
|
||||
@@ -469,13 +417,6 @@
|
||||
<DependentUpon>EditMacro.aspx</DependentUpon>
|
||||
<SubType>ASPXCodeBehind</SubType>
|
||||
</Compile>
|
||||
<Compile Include="Umbraco\Dialogs\MoveOrCopy.aspx.cs">
|
||||
<DependentUpon>moveOrCopy.aspx</DependentUpon>
|
||||
<SubType>ASPXCodeBehind</SubType>
|
||||
</Compile>
|
||||
<Compile Include="Umbraco\Dialogs\MoveOrCopy.aspx.designer.cs">
|
||||
<DependentUpon>moveOrCopy.aspx</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="Umbraco\dialogs\Sort.aspx.cs">
|
||||
<DependentUpon>sort.aspx</DependentUpon>
|
||||
<SubType>ASPXCodeBehind</SubType>
|
||||
@@ -589,8 +530,6 @@
|
||||
<Content Include="Config\Splashes\booting.aspx" />
|
||||
<Content Include="Config\Splashes\noNodes.aspx" />
|
||||
<Content Include="Umbraco\Dashboard\UserControlProxy.aspx" />
|
||||
<Content Include="Umbraco\Create\PartialView.ascx" />
|
||||
<Content Include="Umbraco\Create\User.ascx" />
|
||||
<Content Include="Umbraco\Xslt\Web.config">
|
||||
<SubType>
|
||||
</SubType>
|
||||
@@ -676,8 +615,6 @@
|
||||
<Content Include="Umbraco\Config\Lang\ru.xml" />
|
||||
<Content Include="Umbraco\Config\Lang\zh.xml" />
|
||||
<Content Include="Umbraco\Controls\Tree\CustomTreeService.asmx" />
|
||||
<Content Include="Umbraco\Create\PartialViewMacro.ascx" />
|
||||
<Content Include="Umbraco\Dashboard\ExamineManagement.ascx" />
|
||||
<Content Include="Umbraco\Developer\RelationTypes\EditRelationType.aspx" />
|
||||
<Content Include="Umbraco\Developer\RelationTypes\Images\Bidirectional.png" />
|
||||
<Content Include="Umbraco\Developer\RelationTypes\Images\ParentToChild.png" />
|
||||
@@ -790,17 +727,10 @@
|
||||
<Content Include="Umbraco_Client\DateTimePicker\Images\ui-icons_666666_256x240.png" />
|
||||
<Content Include="Umbraco_Client\DateTimePicker\Images\ui-icons_999999_256x240.png" />
|
||||
<Content Include="Umbraco_Client\DateTimePicker\umbDateTimePicker.js" />
|
||||
<Content Include="Umbraco\Controls\passwordChanger.ascx" />
|
||||
<Content Include="Umbraco\Controls\ProgressBar.ascx" />
|
||||
<Content Include="Umbraco_Client\DateTimePicker\datetimepicker.css" />
|
||||
<Content Include="Umbraco_Client\DateTimePicker\timepicker.js" />
|
||||
<Content Include="Umbraco\Create\DlrScripting.ascx" />
|
||||
<Content Include="Umbraco_Client\Tree\sprites.png" />
|
||||
<Content Include="Umbraco\Controls\Images\ImageViewer.ascx" />
|
||||
<Content Include="Umbraco\Controls\Images\ImageViewer.js" />
|
||||
<Content Include="Umbraco\Controls\Images\ImageViewerUpdater.asmx" />
|
||||
<Content Include="Umbraco\Controls\Images\UploadMediaImage.ascx" />
|
||||
<Content Include="Umbraco\Controls\Images\UploadMediaImage.js" />
|
||||
<Content Include="Umbraco\Controls\Tree\TreeControl.ascx" />
|
||||
<Content Include="Umbraco\Js\UmbracoSpeechBubbleInit.js" />
|
||||
<Content Include="Umbraco\Search\QuickSearch.ascx" />
|
||||
@@ -821,8 +751,6 @@
|
||||
<Content Include="Umbraco\Actions\editContent.aspx" />
|
||||
<Content Include="Umbraco\Actions\preview.aspx" />
|
||||
<Content Include="Umbraco\Actions\publish.aspx" />
|
||||
<Content Include="Umbraco\Channels\rsd.aspx" />
|
||||
<Content Include="Umbraco\Channels\wlwmanifest.aspx" />
|
||||
<Content Include="Umbraco\Config\Lang\da.xml" />
|
||||
<Content Include="Umbraco\Config\Lang\de.xml" />
|
||||
<Content Include="Umbraco\Config\Lang\es.xml" />
|
||||
@@ -831,8 +759,6 @@
|
||||
<Content Include="Umbraco\Config\Lang\nl.xml" />
|
||||
<Content Include="Umbraco\Config\Lang\nb.xml" />
|
||||
<Content Include="Umbraco\Config\Lang\sv.xml" />
|
||||
<Content Include="Umbraco\Css\permissionsEditor.css" />
|
||||
<Content Include="Umbraco\Dialogs\mediaPicker.aspx" />
|
||||
<Content Include="Umbraco\Webservices\MacroContainerService.asmx" />
|
||||
<Content Include="Umbraco_Client\Application\JQuery\jquery.cookie.js" />
|
||||
<Content Include="Umbraco_Client\Imagecropper\Jcrop.gif" />
|
||||
@@ -847,12 +773,9 @@
|
||||
<Content Include="Umbraco_Client\Tree\Themes\Umbraco\throbber.gif" />
|
||||
<Content Include="Umbraco\Developer\Xslt\xsltVisualize.aspx" />
|
||||
<Content Include="Umbraco\Dialogs\empty.htm" />
|
||||
<Content Include="Umbraco\Dialogs\insertMasterpageContent.aspx" />
|
||||
<Content Include="Umbraco\Dialogs\insertMasterpagePlaceholder.aspx" />
|
||||
<Content Include="Umbraco\Dialogs\republish.aspx" />
|
||||
<Content Include="Umbraco\Dialogs\search.aspx" />
|
||||
<Content Include="Umbraco\Dialogs\SendPublish.aspx" />
|
||||
<Content Include="Umbraco\Create\script.ascx" />
|
||||
<Content Include="Umbraco_Client\Tree\treeIcons.css" />
|
||||
<Content Include="Umbraco_Client\Tree\Themes\Umbraco\contextMenuBg.gif" />
|
||||
<Content Include="Umbraco_Client\Application\JQuery\jquery-fieldselection.js" />
|
||||
@@ -862,8 +785,6 @@
|
||||
<Content Include="Umbraco_Client\Tree\NodeDefinition.js" />
|
||||
<Content Include="Umbraco_Client\Tree\UmbracoTree.js" />
|
||||
<Content Include="Umbraco_Client\Application\UmbracoClientManager.js" />
|
||||
<Content Include="Umbraco\Plugins\Tinymce3\InsertAnchor.aspx" />
|
||||
<Content Include="Umbraco\Plugins\Tinymce3\insertChar.aspx" />
|
||||
<Content Include="Umbraco\Webservices\TreeClientService.asmx" />
|
||||
<Content Include="Umbraco_Client\Application\NamespaceManager.js" />
|
||||
<Content Include="Umbraco_Client\Ui\jQueryWresize.js" />
|
||||
@@ -875,17 +796,9 @@
|
||||
<Content Include="Umbraco_Client\Application\JQuery\jquery.autocomplete.js" />
|
||||
<Content Include="Umbraco\Developer\Packages\directoryBrowser.aspx" />
|
||||
<Content Include="Umbraco\Developer\Packages\editPackage.aspx" />
|
||||
<Content Include="Umbraco\Dialogs\about.aspx" />
|
||||
<Content Include="Umbraco\Dialogs\AssignDomain.aspx" />
|
||||
<Content Include="Umbraco\Dialogs\create.aspx" />
|
||||
<Content Include="Umbraco\Dialogs\cruds.aspx" />
|
||||
<Content Include="Umbraco\Dialogs\emptyTrashcan.aspx" />
|
||||
<Content Include="Umbraco\Dialogs\exportDocumenttype.aspx" />
|
||||
<Content Include="Umbraco\Dialogs\imageViewer.aspx" />
|
||||
<Content Include="Umbraco\Dialogs\importDocumenttype.aspx" />
|
||||
<Content Include="Umbraco\Dialogs\insertMacro.aspx" />
|
||||
<Content Include="Umbraco\Dialogs\insertTable.aspx" />
|
||||
<Content Include="Umbraco\Dialogs\moveOrCopy.aspx" />
|
||||
<Content Include="Umbraco\Dialogs\notifications.aspx" />
|
||||
<Content Include="Umbraco\Dialogs\protectPage.aspx" />
|
||||
<Content Include="Umbraco\Dialogs\publish.aspx" />
|
||||
@@ -894,7 +807,6 @@
|
||||
<Content Include="Umbraco\Dialogs\sendToTranslation.aspx" />
|
||||
<Content Include="Umbraco\Dialogs\treePicker.aspx" />
|
||||
<Content Include="Umbraco\Dialogs\umbracoField.aspx" />
|
||||
<Content Include="Umbraco\Dialogs\uploadImage.aspx" />
|
||||
<Content Include="Umbraco\Dialogs\viewAuditTrail.aspx" />
|
||||
<Content Include="Umbraco\Config\Create\UI.xml" />
|
||||
<Content Include="Umbraco\Config\Lang\en.xml">
|
||||
@@ -905,9 +817,6 @@
|
||||
<Content Include="Umbraco\Js\UmbracoSpeechBubbleBackEnd.js" />
|
||||
<Content Include="Umbraco\Js\umbracoUpgradeChecker.js" />
|
||||
<Content Include="Umbraco\Members\ViewMembers.aspx" />
|
||||
<Content Include="Umbraco\Plugins\Tinymce3\insertImage.aspx" />
|
||||
<Content Include="Umbraco\Plugins\Tinymce3\insertLink.aspx" />
|
||||
<Content Include="Umbraco\Plugins\Tinymce3\insertMacro.aspx" />
|
||||
<Content Include="Umbraco\Plugins\Tinymce3\tinymce3tinymceCompress.aspx" />
|
||||
<Content Include="Config\ClientDependency.config">
|
||||
<SubType>Designer</SubType>
|
||||
@@ -1024,8 +933,6 @@
|
||||
<Content Include="Umbraco\Create\xslt.ascx">
|
||||
<SubType>UserControl</SubType>
|
||||
</Content>
|
||||
<Content Include="Umbraco\Css\umbracoGui.css" />
|
||||
<Content Include="Umbraco\Dashboard\LatestEdits.ascx" />
|
||||
<Content Include="Umbraco\Developer\Macros\assemblyBrowser.aspx" />
|
||||
<Content Include="Umbraco\Developer\autoDoc.aspx" />
|
||||
<Content Include="Umbraco\Developer\Macros\editMacro.aspx" />
|
||||
|
||||
@@ -1,31 +0,0 @@
|
||||
<%@ Control Language="C#" AutoEventWireup="true" CodeBehind="PartialView.ascx.cs" Inherits="Umbraco.Web.UI.Umbraco.Create.PartialView" %>
|
||||
<%@ Import Namespace="umbraco" %>
|
||||
<%@ Register TagPrefix="cc1" Namespace="umbraco.uicontrols" Assembly="controls" %>
|
||||
|
||||
<cc1:Pane runat="server">
|
||||
<cc1:PropertyPanel runat="server" Text="Filename (without .cshtml, use / to make folders)">
|
||||
<asp:TextBox ID="FileName" runat="server" CssClass="bigInput input-large-type input-block-level"></asp:TextBox>
|
||||
<asp:RequiredFieldValidator ID="RequiredFieldValidator1"
|
||||
CssClass="text-error" Display="Dynamic"
|
||||
ErrorMessage="*" ControlToValidate="FileName" runat="server">*</asp:RequiredFieldValidator>
|
||||
<asp:RegularExpressionValidator runat="server" ID="EndsWithValidator"
|
||||
CssClass="text-error" Display="Dynamic"
|
||||
ErrorMessage="Cannot end with '/'" ControlToValidate="FileName" ValidationExpression=".*[^/\.]$">
|
||||
Cannot end with '/' or '.'
|
||||
</asp:RegularExpressionValidator>
|
||||
</cc1:PropertyPanel>
|
||||
|
||||
<cc1:PropertyPanel runat="server" Text="Choose a snippet:">
|
||||
<asp:ListBox ID="PartialViewTemplate" runat="server" CssClass="bigInput input-large-type input-block-level" Rows="1" SelectionMode="Single"/>
|
||||
</cc1:PropertyPanel>
|
||||
</cc1:Pane>
|
||||
|
||||
<!-- added to support missing postback on enter in IE -->
|
||||
<asp:TextBox runat="server" Style="visibility: hidden; display: none;" ID="Textbox1" />
|
||||
<input type="hidden" name="nodeType" value="-1">
|
||||
|
||||
|
||||
<cc1:Pane runat="server" CssClass="btn-toolbar umb-btn-toolbar">
|
||||
<a href="#" class="btn btn-link" onclick="UmbClientMgr.closeModalWindow()"><%=umbraco.ui.Text("cancel")%></a>
|
||||
<asp:Button ID="sbmt" runat="server" CssClass="btn btn-primary" Text="Create" OnClick="SubmitButton_Click"></asp:Button>
|
||||
</cc1:Pane>
|
||||
@@ -1,67 +0,0 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.IO;
|
||||
using System.Linq;
|
||||
using System.Web.UI;
|
||||
using System.Web.UI.WebControls;
|
||||
using umbraco.BasePages;
|
||||
using Umbraco.Core;
|
||||
using Umbraco.Core.IO;
|
||||
using Umbraco.Core.Services;
|
||||
using umbraco.presentation.create;
|
||||
|
||||
namespace Umbraco.Web.UI.Umbraco.Create
|
||||
{
|
||||
public partial class PartialView : UI.Controls.UmbracoUserControl
|
||||
{
|
||||
protected override void OnLoad(EventArgs e)
|
||||
{
|
||||
base.OnLoad(e);
|
||||
DataBind();
|
||||
|
||||
LoadTemplates(PartialViewTemplate);
|
||||
|
||||
// Enable new item in folders to place items in that folder.
|
||||
if (Request["nodeType"] == "partialViewsFolder")
|
||||
FileName.Text = Request["nodeId"].EnsureEndsWith('/');
|
||||
}
|
||||
|
||||
private void LoadTemplates(ListControl list)
|
||||
{
|
||||
var fileService = (FileService)Services.FileService;
|
||||
var snippets = fileService.GetPartialViewSnippetNames(
|
||||
//ignore these
|
||||
"Gallery",
|
||||
"ListChildPagesFromChangeableSource",
|
||||
"ListChildPagesOrderedByProperty",
|
||||
"ListImagesFromMediaFolder");
|
||||
|
||||
foreach (var snippet in snippets)
|
||||
{
|
||||
var liText = snippet.SplitPascalCasing().ToFirstUpperInvariant();
|
||||
list.Items.Add(new ListItem(liText, snippet));
|
||||
}
|
||||
}
|
||||
|
||||
protected void SubmitButton_Click(object sender, System.EventArgs e)
|
||||
{
|
||||
if (Page.IsValid)
|
||||
{
|
||||
//Seriously, need to overhaul create dialogs, this is rediculous:
|
||||
// http://issues.umbraco.org/issue/U4-1373
|
||||
|
||||
var createMacroVal = 0;
|
||||
|
||||
string returnUrl = dialogHandler_temp.Create(Request.GetItemAsString("nodeType"),
|
||||
createMacroVal, //apparently we need to pass this value to 'ParentID'... of course! :P then we'll extract it in PartialViewTasks to create it.
|
||||
PartialViewTemplate.SelectedValue + "|||" + FileName.Text);
|
||||
|
||||
BasePage.Current.ClientTools
|
||||
.ChangeContentFrameUrl(returnUrl)
|
||||
.ChildNodeCreated()
|
||||
.CloseModalWindow();
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1,69 +0,0 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <auto-generated>
|
||||
// This code was generated by a tool.
|
||||
//
|
||||
// Changes to this file may cause incorrect behavior and will be lost if
|
||||
// the code is regenerated.
|
||||
// </auto-generated>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace Umbraco.Web.UI.Umbraco.Create {
|
||||
|
||||
|
||||
public partial class PartialView {
|
||||
|
||||
/// <summary>
|
||||
/// FileName control.
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// Auto-generated field.
|
||||
/// To modify move field declaration from designer file to code-behind file.
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.TextBox FileName;
|
||||
|
||||
/// <summary>
|
||||
/// RequiredFieldValidator1 control.
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// Auto-generated field.
|
||||
/// To modify move field declaration from designer file to code-behind file.
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.RequiredFieldValidator RequiredFieldValidator1;
|
||||
|
||||
/// <summary>
|
||||
/// EndsWithValidator control.
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// Auto-generated field.
|
||||
/// To modify move field declaration from designer file to code-behind file.
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.RegularExpressionValidator EndsWithValidator;
|
||||
|
||||
/// <summary>
|
||||
/// PartialViewTemplate control.
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// Auto-generated field.
|
||||
/// To modify move field declaration from designer file to code-behind file.
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.ListBox PartialViewTemplate;
|
||||
|
||||
/// <summary>
|
||||
/// Textbox1 control.
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// Auto-generated field.
|
||||
/// To modify move field declaration from designer file to code-behind file.
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.TextBox Textbox1;
|
||||
|
||||
/// <summary>
|
||||
/// sbmt control.
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// Auto-generated field.
|
||||
/// To modify move field declaration from designer file to code-behind file.
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Button sbmt;
|
||||
}
|
||||
}
|
||||
@@ -38,5 +38,4 @@
|
||||
<package id="System.Collections.Immutable" version="1.1.36" targetFramework="net45" />
|
||||
<package id="System.Reflection.Metadata" version="1.0.21" targetFramework="net45" />
|
||||
<package id="Umbraco.ModelsBuilder" version="3.0.7" targetFramework="net45" />
|
||||
<package id="xmlrpcnet" version="2.5.0" targetFramework="net45" />
|
||||
</packages>
|
||||
@@ -1,20 +0,0 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<%@ Page Language="C#" AutoEventWireup="true" Inherits="System.Web.UI.Page" %>
|
||||
<%@ Import Namespace="Umbraco.Core.IO" %>
|
||||
<script runat="server">
|
||||
protected override void OnInit(EventArgs e)
|
||||
{
|
||||
Response.ContentType = "text/xml";
|
||||
}
|
||||
</script>
|
||||
<rsd version="1.0" xmlns="http://archipelago.phrasewise.com/rsd">
|
||||
<service>
|
||||
<engineName>umbraco</engineName>
|
||||
<engineLink>http://umbraco.org/</engineLink>
|
||||
<homePageLink>http://<%=Request.ServerVariables["SERVER_NAME"]%></homePageLink>
|
||||
<apis>
|
||||
<api name="MetaWeblog" blogID="1" preferred="true" apiLink="http://<%=Request.ServerVariables["SERVER_NAME"]%><%=IOHelper.ResolveUrl(SystemDirectories.Umbraco) %>/channels.aspx" />
|
||||
<api name="Blogger" blogID="1" preferred="false" apiLink="http://<%=Request.ServerVariables["SERVER_NAME"]%><%=IOHelper.ResolveUrl(SystemDirectories.Umbraco) %>/channels.aspx" />
|
||||
</apis>
|
||||
</service>
|
||||
</rsd>
|
||||
@@ -1,51 +0,0 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<%@ Page Language="C#" AutoEventWireup="true" Inherits="System.Web.UI.Page" %>
|
||||
<%@ Import Namespace="Umbraco.Core.IO" %>
|
||||
<%@ Import Namespace="umbraco" %>
|
||||
<script runat="server">
|
||||
protected override void OnInit(EventArgs e)
|
||||
{
|
||||
Response.ContentType = "text/xml";
|
||||
}
|
||||
protected override void OnLoad(EventArgs e)
|
||||
{
|
||||
var useXhtml = false;
|
||||
if (bool.TryParse(GlobalSettings.EditXhtmlMode, out useXhtml) && !useXhtml)
|
||||
{
|
||||
xhtml.Text = "no";
|
||||
}
|
||||
else
|
||||
{
|
||||
xhtml.Text = "yes";
|
||||
}
|
||||
}
|
||||
</script>
|
||||
<manifest xmlns="http://schemas.microsoft.com/wlw/manifest/weblog">
|
||||
<weblog>
|
||||
<imageUrl>http://umbraco.org/images/liveWriterIcon.png</imageUrl>
|
||||
<watermarkImageUrl>http://umbraco.org/images/liveWriterWatermark.png</watermarkImageUrl>
|
||||
<homepageLinkText>View your site/weblog</homepageLinkText>
|
||||
<adminLinkText>Edit your site/weblog</adminLinkText>
|
||||
<adminUrl>{blog-homepage-url}<%= IOHelper.ResolveUrl(SystemDirectories.Umbraco) %>/</adminUrl>
|
||||
<postEditingUrl>{blog-homepage-url}<%= IOHelper.ResolveUrl(SystemDirectories.Umbraco)%>/actions/editContent.aspx?id={post-id}</postEditingUrl>
|
||||
|
||||
</weblog>
|
||||
<views>
|
||||
<default>WebLayout</default>
|
||||
</views>
|
||||
<options>
|
||||
<supportsScripts>Yes</supportsScripts>
|
||||
<supportsEmbeds>Yes</supportsEmbeds>
|
||||
<supportsHtmlTitles>Yes</supportsHtmlTitles>
|
||||
<supportsEmptyTitles>No</supportsEmptyTitles>
|
||||
<maxRecentPosts>100</maxRecentPosts>
|
||||
<supportsNewCategories>Yes</supportsNewCategories>
|
||||
<supportsExcerpt>Yes</supportsExcerpt>
|
||||
<supportsPages>No</supportsPages>
|
||||
<supportsPageParent>No</supportsPageParent>
|
||||
<supportsPageOrder>No</supportsPageOrder>
|
||||
<supportsAutoUpdate>Yes</supportsAutoUpdate>
|
||||
<supportsMultipleCategories>Yes</supportsMultipleCategories>
|
||||
<requiresXHTML><asp:Literal runat="server" id="xhtml"></asp:Literal></requiresXHTML>
|
||||
</options>
|
||||
</manifest>
|
||||
@@ -1,20 +1,5 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<createUI>
|
||||
<nodeType alias="templates">
|
||||
<header>Template</header>
|
||||
<usercontrol>/create/simple.ascx</usercontrol>
|
||||
<tasks>
|
||||
<delete assembly="umbraco" type="templateTasks" />
|
||||
<create assembly="umbraco" type="templateTasks" />
|
||||
</tasks>
|
||||
</nodeType>
|
||||
<nodeType alias="inittemplates">
|
||||
<header>Template</header>
|
||||
<usercontrol>/create/simple.ascx</usercontrol>
|
||||
<tasks>
|
||||
<create assembly="umbraco" type="templateTasks" />
|
||||
</tasks>
|
||||
</nodeType>
|
||||
<nodeType alias="initmacros">
|
||||
<header>Macro</header>
|
||||
<usercontrol>/create/simple.ascx</usercontrol>
|
||||
@@ -120,56 +105,6 @@
|
||||
<delete assembly="umbraco" type="cacheTasks" />
|
||||
</tasks>
|
||||
</nodeType>
|
||||
<nodeType alias="initpython">
|
||||
<header>Scripting file</header>
|
||||
<usercontrol>/create/DLRScripting.ascx</usercontrol>
|
||||
<tasks>
|
||||
<create assembly="umbraco" type="PythonTasks" />
|
||||
</tasks>
|
||||
</nodeType>
|
||||
<nodeType alias="python">
|
||||
<header>Macro</header>
|
||||
<usercontrol>/create/DLRScripting.ascx</usercontrol>
|
||||
<tasks>
|
||||
<delete assembly="umbraco" type="PythonTasks" />
|
||||
</tasks>
|
||||
</nodeType>
|
||||
<nodeType alias="initdlrscripting">
|
||||
<header>Scripting file</header>
|
||||
<usercontrol>/create/DLRScripting.ascx</usercontrol>
|
||||
<tasks>
|
||||
<create assembly="umbraco" type="DLRScriptingTasks" />
|
||||
</tasks>
|
||||
</nodeType>
|
||||
<nodeType alias="dlrscripting">
|
||||
<header>Macro</header>
|
||||
<usercontrol>/create/DLRScripting.ascx</usercontrol>
|
||||
<tasks>
|
||||
<delete assembly="umbraco" type="DLRScriptingTasks" />
|
||||
</tasks>
|
||||
</nodeType>
|
||||
<nodeType alias="initscripts">
|
||||
<header>Script file</header>
|
||||
<usercontrol>/create/script.ascx</usercontrol>
|
||||
<tasks>
|
||||
<create assembly="umbraco" type="ScriptTasks" />
|
||||
</tasks>
|
||||
</nodeType>
|
||||
<nodeType alias="scriptsFolder">
|
||||
<header>Script file</header>
|
||||
<usercontrol>/create/script.ascx</usercontrol>
|
||||
<tasks>
|
||||
<create assembly="umbraco" type="ScriptTasks" />
|
||||
<delete assembly="umbraco" type="ScriptTasks" />
|
||||
</tasks>
|
||||
</nodeType>
|
||||
<nodeType alias="scripts">
|
||||
<header>Macro</header>
|
||||
<usercontrol>/create/script.ascx</usercontrol>
|
||||
<tasks>
|
||||
<delete assembly="umbraco" type="ScriptTasks" />
|
||||
</tasks>
|
||||
</nodeType>
|
||||
<nodeType alias="initpackager">
|
||||
<header>Package</header>
|
||||
<usercontrol>/create/simple.ascx</usercontrol>
|
||||
@@ -198,13 +133,5 @@
|
||||
<delete assembly="umbraco" type="CreatedPackageTasks" />
|
||||
</tasks>
|
||||
</nodeType>
|
||||
<nodeType alias="partialViews">
|
||||
<header>Macro</header>
|
||||
<usercontrol>/Create/PartialView.ascx</usercontrol>
|
||||
<tasks>
|
||||
<create assembly="umbraco" type="PartialViewTasks" />
|
||||
<delete assembly="umbraco" type="PartialViewTasks" />
|
||||
</tasks>
|
||||
</nodeType>
|
||||
|
||||
</createUI>
|
||||
|
||||
@@ -1,20 +1,5 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<createUI>
|
||||
<nodeType alias="templates">
|
||||
<header>Template</header>
|
||||
<usercontrol>/create/simple.ascx</usercontrol>
|
||||
<tasks>
|
||||
<delete assembly="umbraco" type="templateTasks" />
|
||||
<create assembly="umbraco" type="templateTasks" />
|
||||
</tasks>
|
||||
</nodeType>
|
||||
<nodeType alias="inittemplates">
|
||||
<header>Template</header>
|
||||
<usercontrol>/create/simple.ascx</usercontrol>
|
||||
<tasks>
|
||||
<create assembly="umbraco" type="templateTasks" />
|
||||
</tasks>
|
||||
</nodeType>
|
||||
<nodeType alias="initmacros">
|
||||
<header>Macro</header>
|
||||
<usercontrol>/create/simple.ascx</usercontrol>
|
||||
@@ -120,56 +105,6 @@
|
||||
<delete assembly="umbraco" type="cacheTasks" />
|
||||
</tasks>
|
||||
</nodeType>
|
||||
<nodeType alias="initpython">
|
||||
<header>Scripting file</header>
|
||||
<usercontrol>/create/DLRScripting.ascx</usercontrol>
|
||||
<tasks>
|
||||
<create assembly="umbraco" type="PythonTasks" />
|
||||
</tasks>
|
||||
</nodeType>
|
||||
<nodeType alias="python">
|
||||
<header>Macro</header>
|
||||
<usercontrol>/create/DLRScripting.ascx</usercontrol>
|
||||
<tasks>
|
||||
<delete assembly="umbraco" type="PythonTasks" />
|
||||
</tasks>
|
||||
</nodeType>
|
||||
<nodeType alias="initdlrscripting">
|
||||
<header>Scripting file</header>
|
||||
<usercontrol>/create/DLRScripting.ascx</usercontrol>
|
||||
<tasks>
|
||||
<create assembly="umbraco" type="DLRScriptingTasks" />
|
||||
</tasks>
|
||||
</nodeType>
|
||||
<nodeType alias="dlrscripting">
|
||||
<header>Macro</header>
|
||||
<usercontrol>/create/DLRScripting.ascx</usercontrol>
|
||||
<tasks>
|
||||
<delete assembly="umbraco" type="DLRScriptingTasks" />
|
||||
</tasks>
|
||||
</nodeType>
|
||||
<nodeType alias="initscripts">
|
||||
<header>Script file</header>
|
||||
<usercontrol>/create/script.ascx</usercontrol>
|
||||
<tasks>
|
||||
<create assembly="umbraco" type="ScriptTasks" />
|
||||
</tasks>
|
||||
</nodeType>
|
||||
<nodeType alias="scriptsFolder">
|
||||
<header>Script file</header>
|
||||
<usercontrol>/create/script.ascx</usercontrol>
|
||||
<tasks>
|
||||
<create assembly="umbraco" type="ScriptTasks" />
|
||||
<delete assembly="umbraco" type="ScriptTasks" />
|
||||
</tasks>
|
||||
</nodeType>
|
||||
<nodeType alias="scripts">
|
||||
<header>Macro</header>
|
||||
<usercontrol>/create/script.ascx</usercontrol>
|
||||
<tasks>
|
||||
<delete assembly="umbraco" type="ScriptTasks" />
|
||||
</tasks>
|
||||
</nodeType>
|
||||
<nodeType alias="initpackager">
|
||||
<header>Package</header>
|
||||
<usercontrol>/create/simple.ascx</usercontrol>
|
||||
@@ -198,13 +133,6 @@
|
||||
<delete assembly="umbraco" type="CreatedPackageTasks" />
|
||||
</tasks>
|
||||
</nodeType>
|
||||
<nodeType alias="partialViews">
|
||||
<header>Macro</header>
|
||||
<usercontrol>/Create/PartialView.ascx</usercontrol>
|
||||
<tasks>
|
||||
<create assembly="umbraco" type="PartialViewTasks" />
|
||||
<delete assembly="umbraco" type="PartialViewTasks" />
|
||||
</tasks>
|
||||
</nodeType>
|
||||
|
||||
|
||||
</createUI>
|
||||
|
||||
@@ -29,6 +29,8 @@
|
||||
<key alias="republish">Republish entire site</key>
|
||||
<key alias="restore" version="7.3.0">Restore</key>
|
||||
<key alias="SetPermissionsForThePage">Set permissions for the page %0%</key>
|
||||
<key alias="chooseWhereToMove">Choose where to move</key>
|
||||
<key alias="toInTheTreeStructureBelow">In the tree structure below</key>
|
||||
<key alias="rights">Permissions</key>
|
||||
<key alias="rollback">Rollback</key>
|
||||
<key alias="sendtopublish">Send To Publish</key>
|
||||
|
||||
@@ -28,6 +28,8 @@
|
||||
<key alias="refreshNode">Reload</key>
|
||||
<key alias="republish">Republish entire site</key>
|
||||
<key alias="SetPermissionsForThePage">Set permissions for the page %0%</key>
|
||||
<key alias="chooseWhereToMove">Choose where to move</key>
|
||||
<key alias="toInTheTreeStructureBelow">In the tree structure below</key>
|
||||
<key alias="restore" version="7.3.0">Restore</key>
|
||||
<key alias="rights">Permissions</key>
|
||||
<key alias="rollback">Rollback</key>
|
||||
|
||||
@@ -1,49 +0,0 @@
|
||||
<%@ Control Language="C#" AutoEventWireup="True" CodeBehind="ImageViewer.ascx.cs" Inherits="Umbraco.Web.UI.Umbraco.Controls.Images.ImageViewer" %>
|
||||
<%@ Import Namespace="Umbraco.Core.IO" %>
|
||||
<%@ Register TagPrefix="umb" Namespace="ClientDependency.Core.Controls" Assembly="ClientDependency.Core" %>
|
||||
<umb:JsInclude ID="JsInclude1" runat="server" FilePath="controls/Images/ImageViewer.js" PathNameAlias="UmbracoRoot" />
|
||||
<div id="<%# ClientID %>" class="imageViewer" >
|
||||
|
||||
<asp:MultiView ID="MultiView" runat="server">
|
||||
<asp:View ID="Basic" runat="server">
|
||||
<img src="<%#MediaItemThumbnailPath%>" alt="<%#AltText%>" border="0" class='<%#ImageFound ? "" : "noimage" %>' />
|
||||
</asp:View>
|
||||
<asp:View ID="ImageLink" runat="server">
|
||||
<a href="<%#MediaItemPath%>" title="<%#AltText%>" target="<%#LinkTarget%>">
|
||||
<img src="<%#MediaItemThumbnailPath%>" alt="<%#AltText%>" border="0" class='<%#ImageFound ? "" : "noimage" %>' />
|
||||
</a>
|
||||
</asp:View>
|
||||
<asp:View ID="ThumbnailPreview" runat="server">
|
||||
<div class="bgImage"
|
||||
style="width: 105px; height: 105px; background: #fff center center no-repeat;border: 1px solid #ccc; background-image: url('<%#MediaItemThumbnailPath.Replace(" ", "%20")%>');">
|
||||
</div>
|
||||
</asp:View>
|
||||
</asp:MultiView>
|
||||
|
||||
|
||||
<%--Register the javascript callback method if any.--%>
|
||||
|
||||
<script type="text/javascript">
|
||||
<%#string.IsNullOrEmpty(ClientCallbackMethod) ? "" : ClientCallbackMethod + "('" + MediaItemPath + "','" + AltText + "','" + FileWidth + "','" + FileHeight + "');" %>
|
||||
</script>
|
||||
</div>
|
||||
<%--Ensure that the client API is registered for the image.--%>
|
||||
|
||||
<script type="text/javascript">
|
||||
var opts = {
|
||||
umbPath: "<%# IOHelper.ResolveUrl(SystemDirectories.Umbraco) %>",
|
||||
style: "<%#ViewerStyle.ToString()%>",
|
||||
linkTarget: "<%#LinkTarget%>"
|
||||
};
|
||||
|
||||
if (jQuery.isReady) {
|
||||
//because this may be rendered with AJAX, the doc may already be ready! so just wire it up.
|
||||
jQuery("#<%# ClientID %>").UmbracoImageViewer(opts);
|
||||
}
|
||||
else {
|
||||
jQuery(document).ready(function () {
|
||||
jQuery("#<%# ClientID %>").UmbracoImageViewer(opts);
|
||||
});
|
||||
}
|
||||
</script>
|
||||
|
||||
@@ -1,9 +0,0 @@
|
||||
using System;
|
||||
|
||||
namespace Umbraco.Web.UI.Umbraco.Controls.Images
|
||||
{
|
||||
[Obsolete("This is no longer used and will be removed in future versions")]
|
||||
public partial class ImageViewer : global::umbraco.controls.Images.ImageViewer
|
||||
{
|
||||
}
|
||||
}
|
||||
@@ -1,15 +0,0 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <auto-generated>
|
||||
// This code was generated by a tool.
|
||||
//
|
||||
// Changes to this file may cause incorrect behavior and will be lost if
|
||||
// the code is regenerated.
|
||||
// </auto-generated>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace Umbraco.Web.UI.Umbraco.Controls.Images {
|
||||
|
||||
|
||||
public partial class ImageViewer {
|
||||
}
|
||||
}
|
||||
@@ -1,133 +0,0 @@
|
||||
/// <reference path="/umbraco_client/Application/NamespaceManager.js" />
|
||||
/// <reference path="/umbraco_client/ui/jquery.js" />
|
||||
|
||||
Umbraco.Sys.registerNamespace("Umbraco.Controls");
|
||||
|
||||
(function($) {
|
||||
//jQuery plugin for Umbraco image viewer control
|
||||
$.fn.UmbracoImageViewer = function(opts) {
|
||||
//all options must be specified
|
||||
var conf = $.extend({
|
||||
style: false,
|
||||
linkTarget: "_blank",
|
||||
umbPath: ""
|
||||
}, opts);
|
||||
return this.each(function() {
|
||||
new Umbraco.Controls.ImageViewer().init($(this), conf);
|
||||
});
|
||||
}
|
||||
$.fn.UmbracoImageViewerAPI = function() {
|
||||
/// <summary>exposes the Umbraco Image Viewer api for the selected object</summary>
|
||||
//if there's more than item in the selector, throw exception
|
||||
if ($(this).length != 1) {
|
||||
throw "UmbracoImageViewerAPI selector requires that there be exactly one control selected";
|
||||
};
|
||||
return Umbraco.Controls.ImageViewer.inst[$(this).attr("id")] || null;
|
||||
};
|
||||
Umbraco.Controls.ImageViewer = function() {
|
||||
return {
|
||||
_cntr: ++Umbraco.Controls.ImageViewer.cntr,
|
||||
_containerId: null,
|
||||
_context: null,
|
||||
_serviceUrl: "",
|
||||
_umbPath: "",
|
||||
_style: false,
|
||||
_linkTarget: "",
|
||||
|
||||
init: function(jItem, opts) {
|
||||
//this is stored so that we search the current document/iframe for this object
|
||||
//when calling _getContainer. Before this was not required but for some reason inside the
|
||||
//TinyMCE popup, when doing an ajax call, the context is lost to the jquery item!
|
||||
this._context = jItem.get(0).ownerDocument;
|
||||
|
||||
//store a reference to this api by the id and the counter
|
||||
Umbraco.Controls.ImageViewer.inst[this._cntr] = this;
|
||||
if (!jItem.attr("id")) jItem.attr("id", "UmbImageViewer_" + this._cntr);
|
||||
Umbraco.Controls.ImageViewer.inst[jItem.attr("id")] = Umbraco.Controls.ImageViewer.inst[this._cntr];
|
||||
|
||||
this._containerId = jItem.attr("id");
|
||||
|
||||
this._umbPath = opts.umbPath;
|
||||
this._serviceUrl = this._umbPath + "/controls/Images/ImageViewerUpdater.asmx";
|
||||
this._style = opts.style;
|
||||
this._linkTarget = opts.linkTarget;
|
||||
|
||||
},
|
||||
|
||||
updateImage: function(mediaId, callback) {
|
||||
/// <summary>Updates the image to show the mediaId parameter using AJAX</summary>
|
||||
|
||||
this._showThrobber();
|
||||
|
||||
var _this = this;
|
||||
$.ajax({
|
||||
type: "POST",
|
||||
url: _this._serviceUrl + "/UpdateImage",
|
||||
data: '{ "mediaId": ' + parseInt(mediaId) + ', "style": "' + _this._style + '", "linkTarget": "' + _this._linkTarget + '"}',
|
||||
contentType: "application/json; charset=utf-8",
|
||||
dataType: "json",
|
||||
success: function(msg) {
|
||||
var rHtml = $("<div>").append(msg.d.html); //get the full html response wrapped in temp div
|
||||
_this._updateImageFromAjax(rHtml);
|
||||
if (typeof callback == "function") {
|
||||
//build the parameters to pass back to the callback method
|
||||
var params = {
|
||||
hasImage: _this._getContainer().find("img.noimage").length == 0,
|
||||
mediaId: msg.d.mediaId,
|
||||
width: msg.d.width,
|
||||
height: msg.d.height,
|
||||
url: msg.d.url,
|
||||
alt: msg.d.alt
|
||||
};
|
||||
//call the callback method
|
||||
callback.call(_this, params);
|
||||
}
|
||||
}
|
||||
});
|
||||
},
|
||||
|
||||
showImage: function(path) {
|
||||
/// <summary>This will force the image to show the path passed in </summary>
|
||||
if (this._style != "ThumbnailPreview") {
|
||||
this._getContainer().find("img").attr("src", path);
|
||||
}
|
||||
else {
|
||||
c = this._getContainer().find(".bgImage");
|
||||
c.css("background-image", "url('" + path + "')");
|
||||
}
|
||||
},
|
||||
|
||||
_getContainer: function() {
|
||||
return $("#" + this._containerId, this._context);
|
||||
},
|
||||
|
||||
_updateImageFromAjax: function(rHtml) {
|
||||
this._getContainer().html(rHtml.find(".imageViewer").html()); //replace the html with the inner html of the image viewer response
|
||||
},
|
||||
|
||||
_showThrobber: function() {
|
||||
var c = null;
|
||||
if (this._style != "ThumbnailPreview") {
|
||||
c = this._getContainer().find("img");
|
||||
c.attr("src", this._umbPath + "/images/throbber.gif");
|
||||
c.css("margin-top", ((c.height() - 15) / 2) + "px");
|
||||
c.css("margin-left", ((c.width() - 15) / 2) + "px");
|
||||
}
|
||||
else {
|
||||
c = this._getContainer().find(".bgImage");
|
||||
c.css("background-image", "");
|
||||
c.html("<img id='throbber'/>");
|
||||
var img = c.find("img");
|
||||
img.attr("src", this._umbPath + "/images/throbber.gif");
|
||||
img.css("margin-top", "45px");
|
||||
img.css("margin-left", "45px");
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// instance manager
|
||||
Umbraco.Controls.ImageViewer.cntr = 0;
|
||||
Umbraco.Controls.ImageViewer.inst = {};
|
||||
|
||||
})(jQuery);
|
||||
@@ -1 +0,0 @@
|
||||
<%@ WebService Language="C#" CodeBehind="ImageViewerUpdater.asmx.cs" Class="umbraco.controls.Images.ImageViewerUpdater" %>
|
||||
@@ -1,28 +0,0 @@
|
||||
<%@ Control Language="C#" AutoEventWireup="true" CodeBehind="UploadMediaImage.ascx.cs"
|
||||
Inherits="umbraco.controls.Images.UploadMediaImage" %>
|
||||
<%@ Register TagPrefix="cc1" Namespace="umbraco.uicontrols" Assembly="controls" %>
|
||||
<%@ Register TagPrefix="umb" Namespace="ClientDependency.Core.Controls" Assembly="ClientDependency.Core" %>
|
||||
<%@ Register TagPrefix="ctl" Namespace="umbraco.controls" Assembly="umbraco" %>
|
||||
|
||||
<umb:JsInclude ID="JsInclude1" runat="server" FilePath="controls/Images/UploadMediaImage.js" PathNameAlias="UmbracoRoot" />
|
||||
|
||||
<script type="text/javascript">
|
||||
var uploader_<%=this.ClientID%> = new Umbraco.Controls.UploadMediaImage("<%=TextBoxTitle.ClientID%>", "<%=SubmitButton.ClientID%>", "<%=((Control)UploadField.DataEditor).ClientID%>");
|
||||
</script>
|
||||
|
||||
<cc1:pane id="pane_upload" runat="server">
|
||||
<cc1:PropertyPanel ID="pp_name" runat="server" Text="Name">
|
||||
<asp:TextBox id="TextBoxTitle" runat="server"></asp:TextBox>
|
||||
</cc1:PropertyPanel>
|
||||
<cc1:PropertyPanel ID="pp_file" runat="server" Text="File">
|
||||
<asp:PlaceHolder id="UploadControl" runat="server"></asp:PlaceHolder>
|
||||
</cc1:PropertyPanel>
|
||||
<cc1:PropertyPanel ID="pp_target" runat="server" Text="Save at...">
|
||||
<ctl:ContentPicker runat="server" ID="MediaPickerControl" AppAlias="media" TreeAlias="media"
|
||||
ModalHeight="200" ShowDelete="false" ShowHeader="false" Text='<%#umbraco.BasePages.BasePage.Current.getUser().StartMediaId.ToString()%>' />
|
||||
</cc1:PropertyPanel>
|
||||
<cc1:PropertyPanel ID="pp_button" runat="server" Text=" ">
|
||||
<asp:Button id="SubmitButton" runat="server" Text='<%#umbraco.ui.Text("save")%>' Enabled="false" OnClick="SubmitButton_Click"></asp:Button>
|
||||
</cc1:PropertyPanel>
|
||||
</cc1:pane>
|
||||
<cc1:feedback id="feedback" runat="server" />
|
||||
@@ -1,52 +0,0 @@
|
||||
/// <reference path="/umbraco_client/Application/NamespaceManager.js" />
|
||||
|
||||
Umbraco.Sys.registerNamespace("Umbraco.Controls");
|
||||
|
||||
(function($) {
|
||||
Umbraco.Controls.UploadMediaImage = function(txtBoxTitleID, btnID, uploadFileID) {
|
||||
return {
|
||||
_txtBoxTitleID: txtBoxTitleID,
|
||||
_btnID: btnID,
|
||||
_uplaodFileID: uploadFileID,
|
||||
|
||||
validateImage: function() {
|
||||
// Disable save button
|
||||
var imageTypes = ",jpeg,jpg,gif,bmp,png,tiff,tif,";
|
||||
var tb_title = document.getElementById(this._txtBoxTitleID);
|
||||
var bt_submit = $("#" + this._btnID);
|
||||
var tb_image = document.getElementById(this._uplaodFileID);
|
||||
|
||||
bt_submit.attr("disabled","disabled").css("color", "gray");
|
||||
|
||||
var imageName = tb_image.value;
|
||||
if (imageName.length > 0) {
|
||||
var extension = imageName.substring(imageName.lastIndexOf(".") + 1, imageName.length);
|
||||
if (imageTypes.indexOf(',' + extension.toLowerCase() + ',') > -1) {
|
||||
bt_submit.removeAttr("disabled").css("color", "#000");
|
||||
if (tb_title.value == "") {
|
||||
var curName = imageName.substring(imageName.lastIndexOf("\\") + 1, imageName.length).replace("." + extension, "");
|
||||
var curNameLength = curName.length;
|
||||
var friendlyName = "";
|
||||
for (var i = 0; i < curNameLength; i++) {
|
||||
currentChar = curName.substring(i, i + 1);
|
||||
if (friendlyName.length == 0)
|
||||
currentChar = currentChar.toUpperCase();
|
||||
|
||||
if (i < curNameLength - 1 && friendlyName != '' && curName.substring(i - 1, i) == ' ')
|
||||
currentChar = currentChar.toUpperCase();
|
||||
else if (currentChar != " " && i < curNameLength - 1 && friendlyName != ''
|
||||
&& curName.substring(i-1, i).toUpperCase() != curName.substring(i-1, i)
|
||||
&& currentChar.toUpperCase() == currentChar)
|
||||
friendlyName += " ";
|
||||
|
||||
friendlyName += currentChar;
|
||||
|
||||
}
|
||||
tb_title.value = friendlyName;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
};
|
||||
}
|
||||
})(jQuery);
|
||||
@@ -1,35 +0,0 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Configuration.Provider;
|
||||
using System.Linq;
|
||||
using System.Web;
|
||||
using System.Web.Security;
|
||||
using Umbraco.Core;
|
||||
using Umbraco.Core.Models;
|
||||
using Umbraco.Core.Security;
|
||||
|
||||
namespace Umbraco.Web.UI.Umbraco.Controls
|
||||
{
|
||||
public partial class PasswordChanger : global::umbraco.controls.passwordChanger
|
||||
{
|
||||
protected override void OnPreRender(EventArgs e)
|
||||
{
|
||||
base.OnPreRender(e);
|
||||
|
||||
//always reset the control vals
|
||||
ResetPasswordCheckBox.Checked = false;
|
||||
umbPasswordChanger_passwordCurrent.Text = null;
|
||||
umbPasswordChanger_passwordNew.Text = null;
|
||||
umbPasswordChanger_passwordNewConfirm.Text = null;
|
||||
//reset the flag always
|
||||
IsChangingPasswordField.Value = "false";
|
||||
|
||||
var canReset = Provider.CanResetPassword(ApplicationContext.Current.Services.UserService);
|
||||
|
||||
ResetPlaceHolder.Visible = canReset;
|
||||
|
||||
this.DataBind();
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
@@ -1,69 +0,0 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <auto-generated>
|
||||
// This code was generated by a tool.
|
||||
//
|
||||
// Changes to this file may cause incorrect behavior and will be lost if
|
||||
// the code is regenerated.
|
||||
// </auto-generated>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace Umbraco.Web.UI.Umbraco.Controls {
|
||||
|
||||
|
||||
public partial class PasswordChanger {
|
||||
|
||||
/// <summary>
|
||||
/// ResetPlaceHolder control.
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// Auto-generated field.
|
||||
/// To modify move field declaration from designer file to code-behind file.
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.PlaceHolder ResetPlaceHolder;
|
||||
|
||||
/// <summary>
|
||||
/// CurrentPasswordPlaceHolder control.
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// Auto-generated field.
|
||||
/// To modify move field declaration from designer file to code-behind file.
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.PlaceHolder CurrentPasswordPlaceHolder;
|
||||
|
||||
/// <summary>
|
||||
/// CurrentPasswordValidator control.
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// Auto-generated field.
|
||||
/// To modify move field declaration from designer file to code-behind file.
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.RequiredFieldValidator CurrentPasswordValidator;
|
||||
|
||||
/// <summary>
|
||||
/// NewPasswordRequiredValidator control.
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// Auto-generated field.
|
||||
/// To modify move field declaration from designer file to code-behind file.
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.RequiredFieldValidator NewPasswordRequiredValidator;
|
||||
|
||||
/// <summary>
|
||||
/// NewPasswordLengthValidator control.
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// Auto-generated field.
|
||||
/// To modify move field declaration from designer file to code-behind file.
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.RegularExpressionValidator NewPasswordLengthValidator;
|
||||
|
||||
/// <summary>
|
||||
/// Div1 control.
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// Auto-generated field.
|
||||
/// To modify move field declaration from designer file to code-behind file.
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.HtmlControls.HtmlGenericControl Div1;
|
||||
}
|
||||
}
|
||||
@@ -1,133 +0,0 @@
|
||||
<%@ Control Language="C#" AutoEventWireup="True" CodeBehind="passwordChanger.ascx.cs" Inherits="Umbraco.Web.UI.Umbraco.Controls.PasswordChanger" %>
|
||||
|
||||
<script type="text/javascript">
|
||||
(function ($) {
|
||||
Umbraco.Sys.registerNamespace("Umbraco.Controls");
|
||||
var enablePassRetrieval = <%=Provider.EnablePasswordRetrieval.ToString().ToLower()%>;
|
||||
Umbraco.Controls.PasswordChanger = {
|
||||
toggle: function (e) {
|
||||
if (!$("#umbPasswordChanger").is(":visible")) {
|
||||
this.togglePasswordInputValidators(true);
|
||||
$(e).closest(".umb-el-wrap").replaceWith($("#umbPasswordChanger"));
|
||||
$("#umbPasswordChanger").show();
|
||||
$("#<%=IsChangingPasswordField.ClientID%>").val("true");
|
||||
$(e).hide();
|
||||
}
|
||||
},
|
||||
togglePasswordInputValidators: function(enable) {
|
||||
if (enable) {
|
||||
ValidatorEnable(document.getElementById('<%=NewPasswordRequiredValidator.ClientID %>'), true);
|
||||
ValidatorEnable(document.getElementById('<%=ConfirmPasswordValidator.ClientID %>'), true);
|
||||
ValidatorEnable(document.getElementById('<%=NewPasswordLengthValidator.ClientID %>'), true);
|
||||
if (!enablePassRetrieval) {
|
||||
var currPassVal = document.getElementById('<%=CurrentPasswordValidator.ClientID %>');
|
||||
if (currPassVal) {
|
||||
ValidatorEnable(currPassVal, true);
|
||||
}
|
||||
}
|
||||
}
|
||||
else {
|
||||
var currPassVal = document.getElementById('<%=CurrentPasswordValidator.ClientID %>');
|
||||
if (currPassVal) {
|
||||
ValidatorEnable(currPassVal, false);
|
||||
}
|
||||
ValidatorEnable(document.getElementById('<%=ConfirmPasswordValidator.ClientID %>'), false);
|
||||
ValidatorEnable(document.getElementById('<%=NewPasswordRequiredValidator.ClientID %>'), false);
|
||||
ValidatorEnable(document.getElementById('<%=NewPasswordLengthValidator.ClientID %>'), false);
|
||||
}
|
||||
},
|
||||
toggleReset: function(isChecked) {
|
||||
if (isChecked) {
|
||||
$("#passwordInputArea").hide();
|
||||
this.togglePasswordInputValidators(false);
|
||||
}
|
||||
else {
|
||||
$("#passwordInputArea").show();
|
||||
this.togglePasswordInputValidators(true);
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
$(document).ready(function () {
|
||||
$("#changePasswordButton").click(function() {
|
||||
Umbraco.Controls.PasswordChanger.toggle(this);
|
||||
});
|
||||
$("#<%=ResetPasswordCheckBox.ClientID%>").change(function () {
|
||||
Umbraco.Controls.PasswordChanger.toggleReset(
|
||||
$("#<%=ResetPasswordCheckBox.ClientID%>").is(":checked"));
|
||||
});
|
||||
});
|
||||
|
||||
})(jQuery);
|
||||
</script>
|
||||
|
||||
<a href="#" id="changePasswordButton"><%= umbraco.ui.Text("user", "changePassword") %></a><br />
|
||||
|
||||
<div class="propertyItem" id="umbPasswordChanger" style="display: none;">
|
||||
|
||||
<asp:HiddenField runat="server" ID="IsChangingPasswordField" Value="false" />
|
||||
|
||||
<asp:PlaceHolder runat="server" ID="ResetPlaceHolder">
|
||||
<div class="umb-el-wrap">
|
||||
<label class="control-label" for="<%=ResetPasswordCheckBox.ClientID %>"><%=umbraco.ui.GetText("user", "resetPassword")%></label>
|
||||
<div class="controls controls-row">
|
||||
<asp:CheckBox runat="server" ID="ResetPasswordCheckBox" />
|
||||
</div>
|
||||
</div>
|
||||
</asp:PlaceHolder>
|
||||
|
||||
<div id="passwordInputArea">
|
||||
<asp:PlaceHolder runat="server" ID="CurrentPasswordPlaceHolder" Visible="<%#ShowOldPassword %>">
|
||||
<div class="umb-el-wrap ">
|
||||
<label class="control-label" for="<%=umbPasswordChanger_passwordCurrent.ClientID %>"><%=umbraco.ui.GetText("user", "passwordCurrent")%></label>
|
||||
<div class="controls controls-row">
|
||||
<asp:TextBox ID="umbPasswordChanger_passwordCurrent" autocomplete="off" AutoCompleteType="None" TextMode="password" runat="server"></asp:TextBox>
|
||||
<asp:RequiredFieldValidator ID="CurrentPasswordValidator" Enabled="False" runat="server"
|
||||
Display="Dynamic"
|
||||
ControlToValidate="umbPasswordChanger_passwordCurrent"
|
||||
ErrorMessage="*" />
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</asp:PlaceHolder>
|
||||
|
||||
<div class="umb-el-wrap ">
|
||||
<label class="control-label" for="<%=umbPasswordChanger_passwordNew.ClientID %>"><%=umbraco.ui.GetText("user", "newPassword")%></label>
|
||||
<div class="controls controls-row">
|
||||
<asp:TextBox ID="umbPasswordChanger_passwordNew" autocomplete="off" AutoCompleteType="None" TextMode="password" runat="server"></asp:TextBox>
|
||||
<asp:RequiredFieldValidator ID="NewPasswordRequiredValidator" Enabled="False" runat="server"
|
||||
Display="Dynamic"
|
||||
ControlToValidate="umbPasswordChanger_passwordNew"
|
||||
ErrorMessage="*" />
|
||||
<asp:RegularExpressionValidator ID="NewPasswordLengthValidator" runat="server"
|
||||
Display="Dynamic"
|
||||
ControlToValidate="umbPasswordChanger_passwordNew"
|
||||
ErrorMessage='<%# "Minimum " + Provider.MinRequiredPasswordLength + " characters" %>'
|
||||
ValidationExpression='<%# ".{" + Provider.MinRequiredPasswordLength + "}.*" %>' />
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="umb-el-wrap ">
|
||||
<label class="control-label" for="<%=umbPasswordChanger_passwordNewConfirm.ClientID %>"><%=umbraco.ui.GetText("user", "confirmNewPassword")%></label>
|
||||
<div class="controls controls-row">
|
||||
<asp:TextBox ID="umbPasswordChanger_passwordNewConfirm" autocomplete="off" AutoCompleteType="None" TextMode="password" runat="server"></asp:TextBox>
|
||||
<asp:CompareValidator ID="ConfirmPasswordValidator" runat="server" Enabled="False"
|
||||
Display="Dynamic"
|
||||
ErrorMessage="Passwords must match"
|
||||
ControlToValidate="umbPasswordChanger_passwordNew"
|
||||
ControlToCompare="umbPasswordChanger_passwordNewConfirm"
|
||||
Operator="Equal" />
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
<div id="Div1" runat="server" class="alert alert-success" style="margin-top: 10px; width: 300px;" visible="<%# string.IsNullOrWhiteSpace(ChangingPasswordModel.GeneratedPassword) == false %>">
|
||||
<p style="text-align: center">
|
||||
Password has been reset to<br />
|
||||
<br />
|
||||
<strong><%# ChangingPasswordModel.GeneratedPassword %></strong>
|
||||
</p>
|
||||
</div>
|
||||
@@ -1,40 +0,0 @@
|
||||
<%@ Control Language="C#" AutoEventWireup="True" CodeBehind="DlrScripting.ascx.cs" Inherits="Umbraco.Web.UI.Umbraco.Create.DlrScripting" %>
|
||||
<%@ Import Namespace="umbraco" %>
|
||||
<%@ Register TagPrefix="cc1" Namespace="umbraco.uicontrols" Assembly="controls" %>
|
||||
|
||||
<cc1:Pane runat="server">
|
||||
<cc1:PropertyPanel runat="server" text="Filename (without extension)">
|
||||
<asp:TextBox id="rename" Runat="server" CssClass="bigInput input-large-type input-block-level"></asp:TextBox>
|
||||
<asp:RequiredFieldValidator id="RequiredFieldValidator1" ErrorMessage="*" ControlToValidate="rename" runat="server">*</asp:RequiredFieldValidator>
|
||||
</cc1:PropertyPanel>
|
||||
|
||||
<asp:UpdatePanel ID="UpdatePanel1" runat="server">
|
||||
<ContentTemplate>
|
||||
<cc1:PropertyPanel runat="server" text="Choose a language">
|
||||
<asp:ListBox id="filetype" Runat="server" CssClass="bigInput input-large-type input-block-level" Rows="1"
|
||||
SelectionMode="Single" AutoPostBack="true" OnSelectedIndexChanged="loadTemplates">
|
||||
</asp:ListBox>
|
||||
</cc1:PropertyPanel>
|
||||
<cc1:PropertyPanel runat="server" text="Choose a snippet:">
|
||||
<asp:ListBox id="template" Runat="server" CssClass="bigInput input-large-type input-block-level" Rows="1" SelectionMode="Single">
|
||||
</asp:ListBox>
|
||||
</cc1:PropertyPanel>
|
||||
</ContentTemplate>
|
||||
</asp:UpdatePanel>
|
||||
|
||||
<cc1:PropertyPanel runat="server">
|
||||
<asp:CheckBox ID="createMacro" Runat="server" Checked="true" Text="Create Macro"></asp:CheckBox>
|
||||
<asp:CustomValidator ErrorMessage="<br/>A macro already exists with the specified name" ID="MacroExistsValidator"
|
||||
Display="Dynamic" ForeColor="red"
|
||||
runat="server" OnServerValidate="MacroExistsValidator_OnServerValidate"/>
|
||||
</cc1:PropertyPanel>
|
||||
</cc1:Pane>
|
||||
|
||||
<cc1:Pane runat="server" CssClass="btn-toolbar umb-btn-toolbar">
|
||||
<a href="#" class="btn btn-link" onclick="UmbClientMgr.closeModalWindow()"><%=umbraco.ui.Text("cancel")%></a>
|
||||
<asp:Button id="sbmt" Runat="server" CssClass="btn btn-primary" Text="Save" onclick="sbmt_Click"></asp:Button>
|
||||
</cc1:Pane>
|
||||
|
||||
<!-- added to support missing postback on enter in IE -->
|
||||
<asp:TextBox runat="server" style="visibility:hidden;display:none;" ID="Textbox1"/>
|
||||
<input type="hidden" name="nodeType" value="-1">
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user