Update Form Designer - Better Code - PrepareControlClass() Function.
@@ -10,11 +10,8 @@ load "stdlib.ring"
cCurrentDir = CurrentDir() + "/"
-mergemethods(:FormDesigner_QLabel,:CommonAttributesMethods)
-mergemethods(:FormDesigner_QLabel,:MoveResizeCorners)
-
-mergemethods(:FormDesigner_QPushButton,:MoveResizeCorners)
-mergemethods(:FormDesigner_QPushButton,:CommonAttributesMethods)
+PrepareControlClass(:FormDesigner_QLabel)
+PrepareControlClass(:FormDesigner_QPushButton)
new qApp {
StyleFusion()
@@ -22,6 +19,10 @@ new qApp {
exec()
}
+func PrepareControlClass cClassName
+ mergemethods(cClassName,:MoveResizeCorners)
+ mergemethods(cClassName,:CommonAttributesMethods)
+
Class FormDesignerController from WindowsControllerParent
oView = new FormDesignerView
