diff options
Diffstat (limited to 'sources/plugins/preview')
72 files changed, 620 insertions, 0 deletions
diff --git a/sources/plugins/preview/icons/hidpi/preview-rtl.png b/sources/plugins/preview/icons/hidpi/preview-rtl.png new file mode 100644 index 00000000..cd64e19a --- /dev/null +++ b/sources/plugins/preview/icons/hidpi/preview-rtl.png | |||
Binary files differ | |||
diff --git a/sources/plugins/preview/icons/hidpi/preview.png b/sources/plugins/preview/icons/hidpi/preview.png new file mode 100644 index 00000000..402db20e --- /dev/null +++ b/sources/plugins/preview/icons/hidpi/preview.png | |||
Binary files differ | |||
diff --git a/sources/plugins/preview/icons/preview-rtl.png b/sources/plugins/preview/icons/preview-rtl.png new file mode 100644 index 00000000..1c9d9787 --- /dev/null +++ b/sources/plugins/preview/icons/preview-rtl.png | |||
Binary files differ | |||
diff --git a/sources/plugins/preview/icons/preview.png b/sources/plugins/preview/icons/preview.png new file mode 100644 index 00000000..162b44b8 --- /dev/null +++ b/sources/plugins/preview/icons/preview.png | |||
Binary files differ | |||
diff --git a/sources/plugins/preview/lang/af.js b/sources/plugins/preview/lang/af.js new file mode 100644 index 00000000..c3129122 --- /dev/null +++ b/sources/plugins/preview/lang/af.js | |||
@@ -0,0 +1,7 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.md or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'preview', 'af', { | ||
6 | preview: 'Voorbeeld' | ||
7 | } ); | ||
diff --git a/sources/plugins/preview/lang/ar.js b/sources/plugins/preview/lang/ar.js new file mode 100644 index 00000000..ff24304b --- /dev/null +++ b/sources/plugins/preview/lang/ar.js | |||
@@ -0,0 +1,7 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.md or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'preview', 'ar', { | ||
6 | preview: 'معاينة الصفحة' | ||
7 | } ); | ||
diff --git a/sources/plugins/preview/lang/bg.js b/sources/plugins/preview/lang/bg.js new file mode 100644 index 00000000..d74194d9 --- /dev/null +++ b/sources/plugins/preview/lang/bg.js | |||
@@ -0,0 +1,7 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.md or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'preview', 'bg', { | ||
6 | preview: 'Преглед' | ||
7 | } ); | ||
diff --git a/sources/plugins/preview/lang/bn.js b/sources/plugins/preview/lang/bn.js new file mode 100644 index 00000000..6b6a7a38 --- /dev/null +++ b/sources/plugins/preview/lang/bn.js | |||
@@ -0,0 +1,7 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.md or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'preview', 'bn', { | ||
6 | preview: 'প্রিভিউ' | ||
7 | } ); | ||
diff --git a/sources/plugins/preview/lang/bs.js b/sources/plugins/preview/lang/bs.js new file mode 100644 index 00000000..40f674df --- /dev/null +++ b/sources/plugins/preview/lang/bs.js | |||
@@ -0,0 +1,7 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.md or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'preview', 'bs', { | ||
6 | preview: 'Prikaži' | ||
7 | } ); | ||
diff --git a/sources/plugins/preview/lang/ca.js b/sources/plugins/preview/lang/ca.js new file mode 100644 index 00000000..fe205416 --- /dev/null +++ b/sources/plugins/preview/lang/ca.js | |||
@@ -0,0 +1,7 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.md or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'preview', 'ca', { | ||
6 | preview: 'Visualització prèvia' | ||
7 | } ); | ||
diff --git a/sources/plugins/preview/lang/cs.js b/sources/plugins/preview/lang/cs.js new file mode 100644 index 00000000..6552515a --- /dev/null +++ b/sources/plugins/preview/lang/cs.js | |||
@@ -0,0 +1,7 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.md or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'preview', 'cs', { | ||
6 | preview: 'Náhled' | ||
7 | } ); | ||
diff --git a/sources/plugins/preview/lang/cy.js b/sources/plugins/preview/lang/cy.js new file mode 100644 index 00000000..47db9de0 --- /dev/null +++ b/sources/plugins/preview/lang/cy.js | |||
@@ -0,0 +1,7 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.md or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'preview', 'cy', { | ||
6 | preview: 'Rhagolwg' | ||
7 | } ); | ||
diff --git a/sources/plugins/preview/lang/da.js b/sources/plugins/preview/lang/da.js new file mode 100644 index 00000000..a88b1af3 --- /dev/null +++ b/sources/plugins/preview/lang/da.js | |||
@@ -0,0 +1,7 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.md or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'preview', 'da', { | ||
6 | preview: 'Vis eksempel' | ||
7 | } ); | ||
diff --git a/sources/plugins/preview/lang/de.js b/sources/plugins/preview/lang/de.js new file mode 100644 index 00000000..be6e986c --- /dev/null +++ b/sources/plugins/preview/lang/de.js | |||
@@ -0,0 +1,7 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.md or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'preview', 'de', { | ||
6 | preview: 'Vorschau' | ||
7 | } ); | ||
diff --git a/sources/plugins/preview/lang/el.js b/sources/plugins/preview/lang/el.js new file mode 100644 index 00000000..51dfff2f --- /dev/null +++ b/sources/plugins/preview/lang/el.js | |||
@@ -0,0 +1,7 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.md or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'preview', 'el', { | ||
6 | preview: 'Προεπισκόπιση' | ||
7 | } ); | ||
diff --git a/sources/plugins/preview/lang/en-au.js b/sources/plugins/preview/lang/en-au.js new file mode 100644 index 00000000..ebaa47b2 --- /dev/null +++ b/sources/plugins/preview/lang/en-au.js | |||
@@ -0,0 +1,7 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.md or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'preview', 'en-au', { | ||
6 | preview: 'Preview' | ||
7 | } ); | ||
diff --git a/sources/plugins/preview/lang/en-ca.js b/sources/plugins/preview/lang/en-ca.js new file mode 100644 index 00000000..a6a520db --- /dev/null +++ b/sources/plugins/preview/lang/en-ca.js | |||
@@ -0,0 +1,7 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.md or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'preview', 'en-ca', { | ||
6 | preview: 'Preview' | ||
7 | } ); | ||
diff --git a/sources/plugins/preview/lang/en-gb.js b/sources/plugins/preview/lang/en-gb.js new file mode 100644 index 00000000..21c416d4 --- /dev/null +++ b/sources/plugins/preview/lang/en-gb.js | |||
@@ -0,0 +1,7 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.md or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'preview', 'en-gb', { | ||
6 | preview: 'Preview' | ||
7 | } ); | ||
diff --git a/sources/plugins/preview/lang/en.js b/sources/plugins/preview/lang/en.js new file mode 100644 index 00000000..093335a9 --- /dev/null +++ b/sources/plugins/preview/lang/en.js | |||
@@ -0,0 +1,7 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.md or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'preview', 'en', { | ||
6 | preview: 'Preview' | ||
7 | } ); | ||
diff --git a/sources/plugins/preview/lang/eo.js b/sources/plugins/preview/lang/eo.js new file mode 100644 index 00000000..8c29fb80 --- /dev/null +++ b/sources/plugins/preview/lang/eo.js | |||
@@ -0,0 +1,7 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.md or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'preview', 'eo', { | ||
6 | preview: 'Vidigi Aspekton' | ||
7 | } ); | ||
diff --git a/sources/plugins/preview/lang/es.js b/sources/plugins/preview/lang/es.js new file mode 100644 index 00000000..5562fb8f --- /dev/null +++ b/sources/plugins/preview/lang/es.js | |||
@@ -0,0 +1,7 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.md or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'preview', 'es', { | ||
6 | preview: 'Vista Previa' | ||
7 | } ); | ||
diff --git a/sources/plugins/preview/lang/et.js b/sources/plugins/preview/lang/et.js new file mode 100644 index 00000000..88685f93 --- /dev/null +++ b/sources/plugins/preview/lang/et.js | |||
@@ -0,0 +1,7 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.md or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'preview', 'et', { | ||
6 | preview: 'Eelvaade' | ||
7 | } ); | ||
diff --git a/sources/plugins/preview/lang/eu.js b/sources/plugins/preview/lang/eu.js new file mode 100644 index 00000000..683e157a --- /dev/null +++ b/sources/plugins/preview/lang/eu.js | |||
@@ -0,0 +1,7 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.md or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'preview', 'eu', { | ||
6 | preview: 'Aurrebista' | ||
7 | } ); | ||
diff --git a/sources/plugins/preview/lang/fa.js b/sources/plugins/preview/lang/fa.js new file mode 100644 index 00000000..f3e3ce3a --- /dev/null +++ b/sources/plugins/preview/lang/fa.js | |||
@@ -0,0 +1,7 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.md or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'preview', 'fa', { | ||
6 | preview: 'پیشنمایش' | ||
7 | } ); | ||
diff --git a/sources/plugins/preview/lang/fi.js b/sources/plugins/preview/lang/fi.js new file mode 100644 index 00000000..f8322356 --- /dev/null +++ b/sources/plugins/preview/lang/fi.js | |||
@@ -0,0 +1,7 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.md or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'preview', 'fi', { | ||
6 | preview: 'Esikatsele' | ||
7 | } ); | ||
diff --git a/sources/plugins/preview/lang/fo.js b/sources/plugins/preview/lang/fo.js new file mode 100644 index 00000000..0a364971 --- /dev/null +++ b/sources/plugins/preview/lang/fo.js | |||
@@ -0,0 +1,7 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.md or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'preview', 'fo', { | ||
6 | preview: 'Frumsýning' | ||
7 | } ); | ||
diff --git a/sources/plugins/preview/lang/fr-ca.js b/sources/plugins/preview/lang/fr-ca.js new file mode 100644 index 00000000..6e67d06a --- /dev/null +++ b/sources/plugins/preview/lang/fr-ca.js | |||
@@ -0,0 +1,7 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.md or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'preview', 'fr-ca', { | ||
6 | preview: 'Prévisualiser' | ||
7 | } ); | ||
diff --git a/sources/plugins/preview/lang/fr.js b/sources/plugins/preview/lang/fr.js new file mode 100644 index 00000000..fc164303 --- /dev/null +++ b/sources/plugins/preview/lang/fr.js | |||
@@ -0,0 +1,7 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.md or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'preview', 'fr', { | ||
6 | preview: 'Aperçu' | ||
7 | } ); | ||
diff --git a/sources/plugins/preview/lang/gl.js b/sources/plugins/preview/lang/gl.js new file mode 100644 index 00000000..6a446582 --- /dev/null +++ b/sources/plugins/preview/lang/gl.js | |||
@@ -0,0 +1,7 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.md or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'preview', 'gl', { | ||
6 | preview: 'Vista previa' | ||
7 | } ); | ||
diff --git a/sources/plugins/preview/lang/gu.js b/sources/plugins/preview/lang/gu.js new file mode 100644 index 00000000..c9f8906f --- /dev/null +++ b/sources/plugins/preview/lang/gu.js | |||
@@ -0,0 +1,7 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.md or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'preview', 'gu', { | ||
6 | preview: 'પૂર્વદર્શન' | ||
7 | } ); | ||
diff --git a/sources/plugins/preview/lang/he.js b/sources/plugins/preview/lang/he.js new file mode 100644 index 00000000..792a1170 --- /dev/null +++ b/sources/plugins/preview/lang/he.js | |||
@@ -0,0 +1,7 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.md or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'preview', 'he', { | ||
6 | preview: 'תצוגה מקדימה' | ||
7 | } ); | ||
diff --git a/sources/plugins/preview/lang/hi.js b/sources/plugins/preview/lang/hi.js new file mode 100644 index 00000000..92c7e40d --- /dev/null +++ b/sources/plugins/preview/lang/hi.js | |||
@@ -0,0 +1,7 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.md or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'preview', 'hi', { | ||
6 | preview: 'प्रीव्यू' | ||
7 | } ); | ||
diff --git a/sources/plugins/preview/lang/hr.js b/sources/plugins/preview/lang/hr.js new file mode 100644 index 00000000..a489a418 --- /dev/null +++ b/sources/plugins/preview/lang/hr.js | |||
@@ -0,0 +1,7 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.md or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'preview', 'hr', { | ||
6 | preview: 'Pregledaj' | ||
7 | } ); | ||
diff --git a/sources/plugins/preview/lang/hu.js b/sources/plugins/preview/lang/hu.js new file mode 100644 index 00000000..8ae9d9fd --- /dev/null +++ b/sources/plugins/preview/lang/hu.js | |||
@@ -0,0 +1,7 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.md or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'preview', 'hu', { | ||
6 | preview: 'Előnézet' | ||
7 | } ); | ||
diff --git a/sources/plugins/preview/lang/id.js b/sources/plugins/preview/lang/id.js new file mode 100644 index 00000000..88cf3620 --- /dev/null +++ b/sources/plugins/preview/lang/id.js | |||
@@ -0,0 +1,7 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.md or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'preview', 'id', { | ||
6 | preview: 'Pratinjau' | ||
7 | } ); | ||
diff --git a/sources/plugins/preview/lang/is.js b/sources/plugins/preview/lang/is.js new file mode 100644 index 00000000..7f407390 --- /dev/null +++ b/sources/plugins/preview/lang/is.js | |||
@@ -0,0 +1,7 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.md or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'preview', 'is', { | ||
6 | preview: 'Forskoða' | ||
7 | } ); | ||
diff --git a/sources/plugins/preview/lang/it.js b/sources/plugins/preview/lang/it.js new file mode 100644 index 00000000..f2767ba2 --- /dev/null +++ b/sources/plugins/preview/lang/it.js | |||
@@ -0,0 +1,7 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.md or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'preview', 'it', { | ||
6 | preview: 'Anteprima' | ||
7 | } ); | ||
diff --git a/sources/plugins/preview/lang/ja.js b/sources/plugins/preview/lang/ja.js new file mode 100644 index 00000000..80eea689 --- /dev/null +++ b/sources/plugins/preview/lang/ja.js | |||
@@ -0,0 +1,7 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.md or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'preview', 'ja', { | ||
6 | preview: 'プレビュー' | ||
7 | } ); | ||
diff --git a/sources/plugins/preview/lang/ka.js b/sources/plugins/preview/lang/ka.js new file mode 100644 index 00000000..d597a2c3 --- /dev/null +++ b/sources/plugins/preview/lang/ka.js | |||
@@ -0,0 +1,7 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.md or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'preview', 'ka', { | ||
6 | preview: 'გადახედვა' | ||
7 | } ); | ||
diff --git a/sources/plugins/preview/lang/km.js b/sources/plugins/preview/lang/km.js new file mode 100644 index 00000000..d19f98e6 --- /dev/null +++ b/sources/plugins/preview/lang/km.js | |||
@@ -0,0 +1,7 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.md or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'preview', 'km', { | ||
6 | preview: 'មើលជាមុន' | ||
7 | } ); | ||
diff --git a/sources/plugins/preview/lang/ko.js b/sources/plugins/preview/lang/ko.js new file mode 100644 index 00000000..252a77fe --- /dev/null +++ b/sources/plugins/preview/lang/ko.js | |||
@@ -0,0 +1,7 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.md or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'preview', 'ko', { | ||
6 | preview: '미리보기' | ||
7 | } ); | ||
diff --git a/sources/plugins/preview/lang/ku.js b/sources/plugins/preview/lang/ku.js new file mode 100644 index 00000000..cf83583c --- /dev/null +++ b/sources/plugins/preview/lang/ku.js | |||
@@ -0,0 +1,7 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.md or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'preview', 'ku', { | ||
6 | preview: 'پێشبینین' | ||
7 | } ); | ||
diff --git a/sources/plugins/preview/lang/lt.js b/sources/plugins/preview/lang/lt.js new file mode 100644 index 00000000..3436bab4 --- /dev/null +++ b/sources/plugins/preview/lang/lt.js | |||
@@ -0,0 +1,7 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.md or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'preview', 'lt', { | ||
6 | preview: 'Peržiūra' | ||
7 | } ); | ||
diff --git a/sources/plugins/preview/lang/lv.js b/sources/plugins/preview/lang/lv.js new file mode 100644 index 00000000..3cdb26b0 --- /dev/null +++ b/sources/plugins/preview/lang/lv.js | |||
@@ -0,0 +1,7 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.md or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'preview', 'lv', { | ||
6 | preview: 'Priekšskatīt' | ||
7 | } ); | ||
diff --git a/sources/plugins/preview/lang/mk.js b/sources/plugins/preview/lang/mk.js new file mode 100644 index 00000000..e5478a84 --- /dev/null +++ b/sources/plugins/preview/lang/mk.js | |||
@@ -0,0 +1,7 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.md or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'preview', 'mk', { | ||
6 | preview: 'Preview' // MISSING | ||
7 | } ); | ||
diff --git a/sources/plugins/preview/lang/mn.js b/sources/plugins/preview/lang/mn.js new file mode 100644 index 00000000..2e578f1e --- /dev/null +++ b/sources/plugins/preview/lang/mn.js | |||
@@ -0,0 +1,7 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.md or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'preview', 'mn', { | ||
6 | preview: 'Уридчлан харах' | ||
7 | } ); | ||
diff --git a/sources/plugins/preview/lang/ms.js b/sources/plugins/preview/lang/ms.js new file mode 100644 index 00000000..64db268a --- /dev/null +++ b/sources/plugins/preview/lang/ms.js | |||
@@ -0,0 +1,7 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.md or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'preview', 'ms', { | ||
6 | preview: 'Prebiu' | ||
7 | } ); | ||
diff --git a/sources/plugins/preview/lang/nb.js b/sources/plugins/preview/lang/nb.js new file mode 100644 index 00000000..ea92da7a --- /dev/null +++ b/sources/plugins/preview/lang/nb.js | |||
@@ -0,0 +1,7 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.md or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'preview', 'nb', { | ||
6 | preview: 'Forhåndsvis' | ||
7 | } ); | ||
diff --git a/sources/plugins/preview/lang/nl.js b/sources/plugins/preview/lang/nl.js new file mode 100644 index 00000000..5db2f755 --- /dev/null +++ b/sources/plugins/preview/lang/nl.js | |||
@@ -0,0 +1,7 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.md or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'preview', 'nl', { | ||
6 | preview: 'Voorbeeld' | ||
7 | } ); | ||
diff --git a/sources/plugins/preview/lang/no.js b/sources/plugins/preview/lang/no.js new file mode 100644 index 00000000..7c6c4ce2 --- /dev/null +++ b/sources/plugins/preview/lang/no.js | |||
@@ -0,0 +1,7 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.md or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'preview', 'no', { | ||
6 | preview: 'Forhåndsvis' | ||
7 | } ); | ||
diff --git a/sources/plugins/preview/lang/pl.js b/sources/plugins/preview/lang/pl.js new file mode 100644 index 00000000..1534907a --- /dev/null +++ b/sources/plugins/preview/lang/pl.js | |||
@@ -0,0 +1,7 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.md or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'preview', 'pl', { | ||
6 | preview: 'Podgląd' | ||
7 | } ); | ||
diff --git a/sources/plugins/preview/lang/pt-br.js b/sources/plugins/preview/lang/pt-br.js new file mode 100644 index 00000000..0e24087d --- /dev/null +++ b/sources/plugins/preview/lang/pt-br.js | |||
@@ -0,0 +1,7 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.md or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'preview', 'pt-br', { | ||
6 | preview: 'Visualizar' | ||
7 | } ); | ||
diff --git a/sources/plugins/preview/lang/pt.js b/sources/plugins/preview/lang/pt.js new file mode 100644 index 00000000..709fe77f --- /dev/null +++ b/sources/plugins/preview/lang/pt.js | |||
@@ -0,0 +1,7 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.md or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'preview', 'pt', { | ||
6 | preview: 'Pré-visualizar' | ||
7 | } ); | ||
diff --git a/sources/plugins/preview/lang/ro.js b/sources/plugins/preview/lang/ro.js new file mode 100644 index 00000000..5e23b41e --- /dev/null +++ b/sources/plugins/preview/lang/ro.js | |||
@@ -0,0 +1,7 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.md or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'preview', 'ro', { | ||
6 | preview: 'Previzualizare' | ||
7 | } ); | ||
diff --git a/sources/plugins/preview/lang/ru.js b/sources/plugins/preview/lang/ru.js new file mode 100644 index 00000000..9e1556ef --- /dev/null +++ b/sources/plugins/preview/lang/ru.js | |||
@@ -0,0 +1,7 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.md or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'preview', 'ru', { | ||
6 | preview: 'Предварительный просмотр' | ||
7 | } ); | ||
diff --git a/sources/plugins/preview/lang/si.js b/sources/plugins/preview/lang/si.js new file mode 100644 index 00000000..c03c538e --- /dev/null +++ b/sources/plugins/preview/lang/si.js | |||
@@ -0,0 +1,7 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.md or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'preview', 'si', { | ||
6 | preview: 'නැවත ' | ||
7 | } ); | ||
diff --git a/sources/plugins/preview/lang/sk.js b/sources/plugins/preview/lang/sk.js new file mode 100644 index 00000000..380b2364 --- /dev/null +++ b/sources/plugins/preview/lang/sk.js | |||
@@ -0,0 +1,7 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.md or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'preview', 'sk', { | ||
6 | preview: 'Náhľad' | ||
7 | } ); | ||
diff --git a/sources/plugins/preview/lang/sl.js b/sources/plugins/preview/lang/sl.js new file mode 100644 index 00000000..aeec46db --- /dev/null +++ b/sources/plugins/preview/lang/sl.js | |||
@@ -0,0 +1,7 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.md or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'preview', 'sl', { | ||
6 | preview: 'Predogled' | ||
7 | } ); | ||
diff --git a/sources/plugins/preview/lang/sq.js b/sources/plugins/preview/lang/sq.js new file mode 100644 index 00000000..8e001b8a --- /dev/null +++ b/sources/plugins/preview/lang/sq.js | |||
@@ -0,0 +1,7 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.md or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'preview', 'sq', { | ||
6 | preview: 'Parashiko' | ||
7 | } ); | ||
diff --git a/sources/plugins/preview/lang/sr-latn.js b/sources/plugins/preview/lang/sr-latn.js new file mode 100644 index 00000000..7338823b --- /dev/null +++ b/sources/plugins/preview/lang/sr-latn.js | |||
@@ -0,0 +1,7 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.md or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'preview', 'sr-latn', { | ||
6 | preview: 'Izgled stranice' | ||
7 | } ); | ||
diff --git a/sources/plugins/preview/lang/sr.js b/sources/plugins/preview/lang/sr.js new file mode 100644 index 00000000..273d4193 --- /dev/null +++ b/sources/plugins/preview/lang/sr.js | |||
@@ -0,0 +1,7 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.md or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'preview', 'sr', { | ||
6 | preview: 'Изглед странице' | ||
7 | } ); | ||
diff --git a/sources/plugins/preview/lang/sv.js b/sources/plugins/preview/lang/sv.js new file mode 100644 index 00000000..d1b34367 --- /dev/null +++ b/sources/plugins/preview/lang/sv.js | |||
@@ -0,0 +1,7 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.md or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'preview', 'sv', { | ||
6 | preview: 'Förhandsgranska' | ||
7 | } ); | ||
diff --git a/sources/plugins/preview/lang/th.js b/sources/plugins/preview/lang/th.js new file mode 100644 index 00000000..25b5b49e --- /dev/null +++ b/sources/plugins/preview/lang/th.js | |||
@@ -0,0 +1,7 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.md or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'preview', 'th', { | ||
6 | preview: 'ดูหน้าเอกสารตัวอย่าง' | ||
7 | } ); | ||
diff --git a/sources/plugins/preview/lang/tr.js b/sources/plugins/preview/lang/tr.js new file mode 100644 index 00000000..5f034bb4 --- /dev/null +++ b/sources/plugins/preview/lang/tr.js | |||
@@ -0,0 +1,7 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.md or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'preview', 'tr', { | ||
6 | preview: 'Ön İzleme' | ||
7 | } ); | ||
diff --git a/sources/plugins/preview/lang/tt.js b/sources/plugins/preview/lang/tt.js new file mode 100644 index 00000000..9511dbaf --- /dev/null +++ b/sources/plugins/preview/lang/tt.js | |||
@@ -0,0 +1,7 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.md or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'preview', 'tt', { | ||
6 | preview: 'Карап алу' | ||
7 | } ); | ||
diff --git a/sources/plugins/preview/lang/ug.js b/sources/plugins/preview/lang/ug.js new file mode 100644 index 00000000..0398cd94 --- /dev/null +++ b/sources/plugins/preview/lang/ug.js | |||
@@ -0,0 +1,7 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.md or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'preview', 'ug', { | ||
6 | preview: 'ئالدىن كۆزەت' | ||
7 | } ); | ||
diff --git a/sources/plugins/preview/lang/uk.js b/sources/plugins/preview/lang/uk.js new file mode 100644 index 00000000..20b295dd --- /dev/null +++ b/sources/plugins/preview/lang/uk.js | |||
@@ -0,0 +1,7 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.md or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'preview', 'uk', { | ||
6 | preview: 'Попередній перегляд' | ||
7 | } ); | ||
diff --git a/sources/plugins/preview/lang/vi.js b/sources/plugins/preview/lang/vi.js new file mode 100644 index 00000000..e7f3c799 --- /dev/null +++ b/sources/plugins/preview/lang/vi.js | |||
@@ -0,0 +1,7 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.md or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'preview', 'vi', { | ||
6 | preview: 'Xem trước' | ||
7 | } ); | ||
diff --git a/sources/plugins/preview/lang/zh-cn.js b/sources/plugins/preview/lang/zh-cn.js new file mode 100644 index 00000000..7a34a0d5 --- /dev/null +++ b/sources/plugins/preview/lang/zh-cn.js | |||
@@ -0,0 +1,7 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.md or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'preview', 'zh-cn', { | ||
6 | preview: '预览' | ||
7 | } ); | ||
diff --git a/sources/plugins/preview/lang/zh.js b/sources/plugins/preview/lang/zh.js new file mode 100644 index 00000000..21f3aceb --- /dev/null +++ b/sources/plugins/preview/lang/zh.js | |||
@@ -0,0 +1,7 @@ | |||
1 | /* | ||
2 | Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | For licensing, see LICENSE.md or http://ckeditor.com/license | ||
4 | */ | ||
5 | CKEDITOR.plugins.setLang( 'preview', 'zh', { | ||
6 | preview: '預覽' | ||
7 | } ); | ||
diff --git a/sources/plugins/preview/plugin.js b/sources/plugins/preview/plugin.js new file mode 100644 index 00000000..5f814995 --- /dev/null +++ b/sources/plugins/preview/plugin.js | |||
@@ -0,0 +1,145 @@ | |||
1 | /** | ||
2 | * @license Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved. | ||
3 | * For licensing, see LICENSE.md or http://ckeditor.com/license | ||
4 | */ | ||
5 | |||
6 | /** | ||
7 | * @fileOverview Preview plugin. | ||
8 | */ | ||
9 | |||
10 | ( function() { | ||
11 | var pluginPath; | ||
12 | |||
13 | var previewCmd = { modes: { wysiwyg: 1, source: 1 }, | ||
14 | canUndo: false, | ||
15 | readOnly: 1, | ||
16 | exec: function( editor ) { | ||
17 | var sHTML, | ||
18 | config = editor.config, | ||
19 | baseTag = config.baseHref ? '<base href="' + config.baseHref + '"/>' : '', | ||
20 | eventData; | ||
21 | |||
22 | if ( config.fullPage ) | ||
23 | sHTML = editor.getData().replace( /<head>/, '$&' + baseTag ).replace( /[^>]*(?=<\/title>)/, '$& — ' + editor.lang.preview.preview ); | ||
24 | else { | ||
25 | var bodyHtml = '<body ', | ||
26 | body = editor.document && editor.document.getBody(); | ||
27 | |||
28 | if ( body ) { | ||
29 | if ( body.getAttribute( 'id' ) ) | ||
30 | bodyHtml += 'id="' + body.getAttribute( 'id' ) + '" '; | ||
31 | if ( body.getAttribute( 'class' ) ) | ||
32 | bodyHtml += 'class="' + body.getAttribute( 'class' ) + '" '; | ||
33 | } | ||
34 | |||
35 | bodyHtml += '>'; | ||
36 | |||
37 | sHTML = editor.config.docType + '<html dir="' + editor.config.contentsLangDirection + '">' + | ||
38 | '<head>' + | ||
39 | baseTag + | ||
40 | '<title>' + editor.lang.preview.preview + '</title>' + | ||
41 | CKEDITOR.tools.buildStyleHtml( editor.config.contentsCss ) + | ||
42 | '</head>' + bodyHtml + | ||
43 | editor.getData() + | ||
44 | '</body></html>'; | ||
45 | } | ||
46 | |||
47 | var iWidth = 640, | ||
48 | // 800 * 0.8, | ||
49 | iHeight = 420, | ||
50 | // 600 * 0.7, | ||
51 | iLeft = 80; // (800 - 0.8 * 800) /2 = 800 * 0.1. | ||
52 | try { | ||
53 | var screen = window.screen; | ||
54 | iWidth = Math.round( screen.width * 0.8 ); | ||
55 | iHeight = Math.round( screen.height * 0.7 ); | ||
56 | iLeft = Math.round( screen.width * 0.1 ); | ||
57 | } catch ( e ) {} | ||
58 | |||
59 | // (#9907) Allow data manipulation before preview is displayed. | ||
60 | // Also don't open the preview window when event cancelled. | ||
61 | if ( editor.fire( 'contentPreview', eventData = { dataValue: sHTML } ) === false ) | ||
62 | return false; | ||
63 | |||
64 | var sOpenUrl = '', | ||
65 | ieLocation; | ||
66 | |||
67 | if ( CKEDITOR.env.ie ) { | ||
68 | window._cke_htmlToLoad = eventData.dataValue; | ||
69 | ieLocation = 'javascript:void( (function(){' + // jshint ignore:line | ||
70 | 'document.open();' + | ||
71 | // Support for custom document.domain. | ||
72 | // Strip comments and replace parent with window.opener in the function body. | ||
73 | ( '(' + CKEDITOR.tools.fixDomain + ')();' ).replace( /\/\/.*?\n/g, '' ).replace( /parent\./g, 'window.opener.' ) + | ||
74 | 'document.write( window.opener._cke_htmlToLoad );' + | ||
75 | 'document.close();' + | ||
76 | 'window.opener._cke_htmlToLoad = null;' + | ||
77 | '})() )'; | ||
78 | // For IE we should use window.location rather than setting url in window.open. (#11146) | ||
79 | sOpenUrl = ''; | ||
80 | } | ||
81 | |||
82 | // With Firefox only, we need to open a special preview page, so | ||
83 | // anchors will work properly on it. (#9047) | ||
84 | if ( CKEDITOR.env.gecko ) { | ||
85 | window._cke_htmlToLoad = eventData.dataValue; | ||
86 | sOpenUrl = CKEDITOR.getUrl( pluginPath + 'preview.html' ); | ||
87 | } | ||
88 | |||
89 | var oWindow = window.open( sOpenUrl, null, 'toolbar=yes,location=no,status=yes,menubar=yes,scrollbars=yes,resizable=yes,width=' + | ||
90 | iWidth + ',height=' + iHeight + ',left=' + iLeft ); | ||
91 | |||
92 | // For IE we want to assign whole js stored in ieLocation, but in case of | ||
93 | // popup blocker activation oWindow variable will be null. (#11597) | ||
94 | if ( CKEDITOR.env.ie && oWindow ) | ||
95 | oWindow.location = ieLocation; | ||
96 | |||
97 | if ( !CKEDITOR.env.ie && !CKEDITOR.env.gecko ) { | ||
98 | var doc = oWindow.document; | ||
99 | doc.open(); | ||
100 | doc.write( eventData.dataValue ); | ||
101 | doc.close(); | ||
102 | } | ||
103 | |||
104 | return true; | ||
105 | } | ||
106 | }; | ||
107 | |||
108 | var pluginName = 'preview'; | ||
109 | |||
110 | // Register a plugin named "preview". | ||
111 | CKEDITOR.plugins.add( pluginName, { | ||
112 | // jscs:disable maximumLineLength | ||
113 | lang: 'af,ar,bg,bn,bs,ca,cs,cy,da,de,el,en,en-au,en-ca,en-gb,eo,es,et,eu,fa,fi,fo,fr,fr-ca,gl,gu,he,hi,hr,hu,id,is,it,ja,ka,km,ko,ku,lt,lv,mk,mn,ms,nb,nl,no,pl,pt,pt-br,ro,ru,si,sk,sl,sq,sr,sr-latn,sv,th,tr,tt,ug,uk,vi,zh,zh-cn', // %REMOVE_LINE_CORE% | ||
114 | // jscs:enable maximumLineLength | ||
115 | icons: 'preview,preview-rtl', // %REMOVE_LINE_CORE% | ||
116 | hidpi: true, // %REMOVE_LINE_CORE% | ||
117 | init: function( editor ) { | ||
118 | |||
119 | // Preview is not used for the inline creator. | ||
120 | if ( editor.elementMode == CKEDITOR.ELEMENT_MODE_INLINE ) | ||
121 | return; | ||
122 | |||
123 | pluginPath = this.path; | ||
124 | |||
125 | editor.addCommand( pluginName, previewCmd ); | ||
126 | editor.ui.addButton && editor.ui.addButton( 'Preview', { | ||
127 | label: editor.lang.preview.preview, | ||
128 | command: pluginName, | ||
129 | toolbar: 'document,40' | ||
130 | } ); | ||
131 | } | ||
132 | } ); | ||
133 | } )(); | ||
134 | |||
135 | /** | ||
136 | * Event fired when executing `preview` command, which allows additional data manipulation. | ||
137 | * With this event, the raw HTML content of the preview window to be displayed can be altered | ||
138 | * or modified. | ||
139 | * | ||
140 | * @event contentPreview | ||
141 | * @member CKEDITOR | ||
142 | * @param {CKEDITOR.editor} editor This editor instance. | ||
143 | * @param data | ||
144 | * @param {String} data.dataValue The data that will go to the preview. | ||
145 | */ | ||
diff --git a/sources/plugins/preview/preview.html b/sources/plugins/preview/preview.html new file mode 100644 index 00000000..8c028262 --- /dev/null +++ b/sources/plugins/preview/preview.html | |||
@@ -0,0 +1,13 @@ | |||
1 | <script> | ||
2 | |||
3 | // Prevent from DOM clobbering. | ||
4 | if ( typeof window.opener._cke_htmlToLoad == 'string' ) { | ||
5 | var doc = document; | ||
6 | doc.open(); | ||
7 | doc.write( window.opener._cke_htmlToLoad ); | ||
8 | doc.close(); | ||
9 | |||
10 | delete window.opener._cke_htmlToLoad; | ||
11 | } | ||
12 | |||
13 | </script> | ||