OSDN Git Service

Ring 1.10 以来となる開発環境の日本語ローカライズ版 (評価版) を追加 (ノートパッド、フォームデザイナー、対話型実行環境、ファイルの検索)。
[ring-lang-081/ring.git] / applications / formdesigner / source / tests / twowindowspart5 / firstwindowController.ring
diff --git a/applications/formdesigner/source/tests/twowindowspart5/firstwindowController.ring b/applications/formdesigner/source/tests/twowindowspart5/firstwindowController.ring
new file mode 100644 (file)
index 0000000..11b5c31
--- /dev/null
@@ -0,0 +1,30 @@
+# Form/Window Controller - Source Code File
+
+load "firstwindowView.ring"
+
+load "secondwindowController.ring"
+
+if IsMainSourceFile() {
+       new qApp {
+               StyleFusion()
+               open_window(:firstwindowController)
+               exec()
+       }
+}
+
+class firstwindowController from windowsControllerParent
+
+       oView = new firstwindowView
+
+       func OpenSecondWindow
+               Open_WindowAndLink(:SecondWindowController,self)
+
+       func SendMessage
+               if isMethod(self,:IsSecondWindow) {
+                       if IsSecondWindow() {
+                               SecondWindow().setMessage("Message from the first window")
+                       }
+               }
+
+       func setMessage cMessage 
+               oView.Label1.setText(cMessage)