Example #1
0
        public static enPlatform getCurrentPlatform()
        {
            enPlatform Platform = enPlatform.Unknown;

            if (Type.GetType("Mono.Runtime") != null)
            {
                Platform = enPlatform.Mono;
#if __IOS__
                Platform = enPlatform.iOS;
#endif
#if __TVOS__
                Platform = enPlatform.tvOS;
#endif
#if __WATCHOS__
                Platform = enPlatform.watchOS;
#endif
#if __ANDROID__
                Platform = enPlatform.Android;
#endif
            }
            else
            {
                Platform = enPlatform.Windows;
#if WINDOWS_PHONE_APP
                Platform = enPlatform.WindowsPhone;
#endif
#if WINDOWS_APP
                Platform = enPlatform.WindowsUniversal;
#endif
            }

            return(Platform);
        }
Example #2
0
        void OpenForm()
        {
            enPlatform platform = (enPlatform)Enum.Parse(typeof(enPlatform), cbbPlatform.SelectedItem.ToString());

            mPlatformWindowMaping[(int)platform].ShowDialog(this);
        }
Example #3
0
 public WindowPlatform(enPlatform _platform)
 {
     InitializeComponent();
     platform = _platform;
     InitializeConfig();
 }