jenkins-bot has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/364750 )

Change subject: refactoring of bsvisualeditor from smwforms to pageforms
......................................................................


refactoring of bsvisualeditor from smwforms to pageforms

Change-Id: I0a55228086861c1e325f75ce7db8cb26dc545c94
---
M extension.json
M includes/BSSMWConnectorHooks.php
M includes/forminputs/BSSFVisualEditor.php
M resources/ext.BSSMWConnector.SF.FreeTextVisualEditor.js
4 files changed, 10 insertions(+), 8 deletions(-)

Approvals:
  Mglaser: Looks good to me, approved
  jenkins-bot: Verified



diff --git a/extension.json b/extension.json
index a279774..11b7f52 100644
--- a/extension.json
+++ b/extension.json
@@ -24,7 +24,7 @@
        },
        "Hooks": {
                "BeforePageDisplay": "BSSMWConnectorHooks::onBeforePageDisplay",
-               "sfFormPrinterSetup": 
"BSSMWConnectorHooks::onSfFormPrinterSetup",
+               "PageForms::FormPrinterSetup": 
"BSSMWConnectorHooks::onPFFormPrinterSetup",
                "BSBookshelfNodeTag": 
"BSSMWConnectorHooks::onBSBookshelfNodeTag",
                "BSBookshelfExportTag": 
"BSSMWConnectorHooks::onBSBookshelfExportTag",
                "NamespaceManager::getMetaFields": 
"BSSMWCNamespaceManager::onGetMetaFields",
diff --git a/includes/BSSMWConnectorHooks.php b/includes/BSSMWConnectorHooks.php
index 870d47c..2ffaa8c 100644
--- a/includes/BSSMWConnectorHooks.php
+++ b/includes/BSSMWConnectorHooks.php
@@ -54,10 +54,10 @@
 
        /**
         * Registers new input types
-        * @param SFFormPrinter $formPrinter
+        * @param PFFormPrinter $formPrinter
         * @return boolean Always true
         */
-       public static function onSfFormPrinterSetup( $formPrinter ) {
+       public static function onPFFormPrinterSetup( PFFormPrinter $formPrinter 
) {
                $formPrinter->registerInputType( 'BSSFVisualEditor' );
                return true;
        }
diff --git a/includes/forminputs/BSSFVisualEditor.php 
b/includes/forminputs/BSSFVisualEditor.php
index f599976..3c0ccb3 100644
--- a/includes/forminputs/BSSFVisualEditor.php
+++ b/includes/forminputs/BSSFVisualEditor.php
@@ -1,6 +1,8 @@
 <?php
 
-class BSSFVisualEditor extends SFTextAreaInput {
+
+
+class BSSFVisualEditor extends PFTextAreaInput {
 
        public static function getName() {
                return 'bsvisualeditor';
@@ -25,8 +27,8 @@
        }
 
        protected function getTextAreaAttributes() {
-               $aParams = parent::getTextAreaAttributes();
-               $aParams['class'] .= ' bs-visualeditor';
-               return $aParams;
+               $textarea_attrs = parent::getTextAreaAttributes();
+               $textarea_attrs['class'] .= ' bs-visualeditor';
+               return $textarea_attrs;
        }
 }
\ No newline at end of file
diff --git a/resources/ext.BSSMWConnector.SF.FreeTextVisualEditor.js 
b/resources/ext.BSSMWConnector.SF.FreeTextVisualEditor.js
index e197ea8..3f3dbc3 100644
--- a/resources/ext.BSSMWConnector.SF.FreeTextVisualEditor.js
+++ b/resources/ext.BSSMWConnector.SF.FreeTextVisualEditor.js
@@ -21,7 +21,7 @@
         //END UGLY COPY&PASTE CODE FROM 
BlueSpiceExtensions/VisualEditor/resoures/bluespice.visualEditor.js
 
         VisualEditor.setConfig( 'semanticForms', {
-            selector: '#sfForm #sf_free_text.bsvisualeditor',
+            selector: '#pfForm #pf_free_text.bsvisualeditor',
             auto_focus: false,
             content_css: currentSiteCSS.join(','),
             /* We need to remove some tools from the toolbar that do not make 
sense in a formedit */

-- 
To view, visit https://gerrit.wikimedia.org/r/364750
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I0a55228086861c1e325f75ce7db8cb26dc545c94
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/BlueSpiceSMWConnector
Gerrit-Branch: master
Gerrit-Owner: Ljonka <l.verhovs...@gmail.com>
Gerrit-Reviewer: Mglaser <gla...@hallowelt.biz>
Gerrit-Reviewer: jenkins-bot <>

_______________________________________________
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits

Reply via email to