コード例 #1
0
 /// <summary>
 /// 将需要监听的对象添加到List之中
 /// </summary>
 /// <param name="listener"></param>
 public void RegisterSender(IWindowListener listener)
 {
     if (!listeners.Contains(listener))
     {
         listeners.Add(listener);
     }
 }
コード例 #2
0
 /// <summary>
 /// 从List之中移除掉监听的对象
 /// </summary>
 /// <param name="listener"></param>
 public void RemoveListener(IWindowListener listener)
 {
     if (listeners.Contains(listener))
     {
         listeners.Remove(listener);
     }
 }
コード例 #3
0
 protected void setWindowConfiguration(WindowConfiguration config)
 {
     windowX            = config.windowX;
     windowY            = config.windowY;
     windowWidth        = config.windowWidth;
     windowHeight       = config.windowHeight;
     windowMinWidth     = config.windowMinWidth;
     windowMinHeight    = config.windowMinHeight;
     windowMaxWidth     = config.windowMaxWidth;
     windowMaxHeight    = config.windowMaxHeight;
     windowResizable    = config.windowResizable;
     windowDecorated    = config.windowDecorated;
     windowMaximized    = config.windowMaximized;
     windowIconFileType = config.windowIconFileType;
     windowIconPaths    = config.windowIconPaths;
     windowListener     = config.windowListener;
     fullscreenMode     = config.fullscreenMode;
     title = config.title;
     initialBackgroundColor = config.initialBackgroundColor;
     initialVisible         = config.initialVisible;
 }
コード例 #4
0
        /// <summary>
        /// 弹窗
        /// </summary>
        /// <param name="type">类型</param>
        /// <param name="callBack">需要回调的对象</param>
        public void AlertWindow(AlertWindowType type, IWindowListener callBack = null)
        {
            if (callBack != null)
            {
                RegisterSender(callBack);
            }
            GameObject tempGo = default(GameObject);

            switch (type)
            {
            case AlertWindowType.SelectWindow:
                tempGo = TSingleTon <PrefabLoad> .Singleton().LoadFromResource("Common", SelectLevelWindow.PrefabName);

                break;
            }
            if (tempGo != null)
            {
                currentWindow = GameObject.Instantiate(tempGo, windowRoot);
                currentWindow.transform.localPosition = Vector3.zero;
                currentAlert = currentWindow.GetComponent <SelectLevelWindow>();
            }
        }
コード例 #5
0
 public void setWindowListener(IWindowListener windowListener)
 {
     this.windowListener = windowListener;
 }
コード例 #6
0
ファイル: Window.cs プロジェクト: yuripourre-forks/libCDX
 internal Window(IApplicationListener listener, ApplicationConfiguration config)
 {
     this.listener  = listener;
     windowListener = config.windowListener;
     this.config    = config;
 }
コード例 #7
0
ファイル: Window.cs プロジェクト: yuripourre-forks/libCDX
 public void setWindowListener(IWindowListener listener)
 {
     windowListener = listener;
 }
コード例 #8
0
 public void SetWindowListener(IWindowListener iWindowListener)
 {
     this.iWindowListener = iWindowListener;
     iWindowListener.StartGameCoreRunner();
 }