当前位置: 首页>>代码示例>>C#>>正文


C# WindowType类代码示例

本文整理汇总了C#中WindowType的典型用法代码示例。如果您正苦于以下问题:C# WindowType类的具体用法?C# WindowType怎么用?C# WindowType使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。


WindowType类属于命名空间,在下文中一共展示了WindowType类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。

示例1: IceTabPageDCCFile

        public IceTabPageDCCFile(WindowType windowType, string sCaption)
            : base(windowType, sCaption)
        {
            InitializeComponent();

            dccFiles = new List<DccFileStruct>();
        }
开发者ID:origins,项目名称:ICEChat,代码行数:7,代码来源:IceTabPageDCCFile.cs

示例2: CustomShortcut

        internal CustomShortcut(
            string shortcutName,
            string targetPath,
            string targetArguments,
            CustomShortcutType shortcutType,
            WindowType windowType,
            string shortcutRootFolder,
            string basicIconToUse = null,
            string workingFolder = null
            )
        {
            var vbsFolderPath =
                DirectoryUtils.GetUniqueDirName(CustomShortcutGetters.CustomShortcutVbsPath + shortcutName) + "\\";
            var shortcutPath = $"{shortcutRootFolder}{new DirectoryInfo(vbsFolderPath).Name}\\{shortcutName}.lnk";


            ShortcutName = shortcutName.CleanInvalidFilenameChars();
            ShortcutItem = new ShortcutItem(shortcutPath);
            TargetPath = targetPath;
            TargetArguments = targetArguments;
            ShortcutType = shortcutType;
            VbsFolderPath = vbsFolderPath;
            WorkingFolder = workingFolder;
            WindowType = windowType;

            Directory.CreateDirectory(VbsFolderPath);

            if (basicIconToUse != null && File.Exists(basicIconToUse)) BasicShortcutIcon = basicIconToUse;
        }
开发者ID:Jonno12345,项目名称:TileIconifier,代码行数:29,代码来源:CustomShortcut.cs

示例3: DropDownBoxListWindow

		public DropDownBoxListWindow (IListDataProvider provider, WindowType windowType) : base (windowType)
		{
			this.DataProvider = provider;
			this.TransientFor = IdeApp.Workbench.RootWindow;
			this.TypeHint = Gdk.WindowTypeHint.Menu;
			this.Decorated = false;
			this.BorderWidth = 1;
			list = new ListWidget (this);
			list.SelectItem += delegate {
				var sel = list.Selection;
				if (sel >= 0 && sel < DataProvider.IconCount) {
					DataProvider.ActivateItem (sel);
					Destroy ();
				}
			};
			SetSizeRequest (list.WidthRequest, list.HeightRequest);
			vScrollbar = new ScrolledWindow ();
			vScrollbar.VScrollbar.SizeAllocated += (o, args) => {
				var minWidth = list.WidthRequest + args.Allocation.Width;
				if (this.Allocation.Width < minWidth)
					SetSizeRequest (minWidth, list.HeightRequest);
			};
			vScrollbar.Child = list;
			var vbox = new VBox ();
			vbox.PackStart (vScrollbar, true, true, 0);
			Add (vbox);
		}
开发者ID:brantwedel,项目名称:monodevelop,代码行数:27,代码来源:DropDownBoxListWindow.cs

示例4: Window

 public Window(WindowType window_type)
     : base(window_type)
 {
     _context = SynchronizationContext.Current;
     CommunicationHandler.addReceiver(this);
     this.SetIconFromFile("masgau.ico");
 }
开发者ID:elkine,项目名称:MASGAU,代码行数:7,代码来源:Window.cs

示例5: GetCurrentMediaItem

        public static bool GetCurrentMediaItem(out MediaItem currentMediaItem, WindowType windowType)
        {
            currentMediaItem = new MediaItem();

            switch (windowType)
            {
                case WindowType.Movie:
                    return GetMovieMediaItem(ref currentMediaItem);

                case WindowType.Show:
                    return GetShowMediaItem(ref currentMediaItem);

                case WindowType.Season:
                    return GetSeasonMediaItem(ref currentMediaItem);

                case WindowType.Episode:
                    return GetEpisodeMediaItem(ref currentMediaItem);

                case WindowType.List:
                    return GetListMediaItem(ref currentMediaItem);

            }

            return false;
        }
开发者ID:ministerkrister,项目名称:Trailers,代码行数:25,代码来源:TraktHandler.cs

示例6: SaveFile

	public void SaveFile(String FilePath, String mainFolder) 
	{
		if(Directory.Exists(mainFolder))
		{
			if(File.Exists(FilePath) || Directory.Exists(FilePath))
			{
				WindowOpen = true;
				WinType = WindowType.Save;
				DragStat.Dragging = false;    // Ensure nothing is being draged.
				
				FileToSave = FilePath;
				
				MainFolder = mainFolder; // example: Application.dataPath/Saves;
				GetAllSubDirectoriesAndFiles( MainFolder );
				
				AddWidth();
				AddScrollPosition(0);
				AddPath(MainFolder, 0);
			}
			else Debug.LogError("I need a path for a temporary save file that actually exists!");
		}
		else
		{
			if(File.Exists(mainFolder)) Debug.LogError("I need a main directory, not a file!");
			else Debug.LogError("I need a path for a main directory that actually exists!");
		}
	}
开发者ID:Master-Machines,项目名称:MusicEngine,代码行数:27,代码来源:Browser.cs

示例7: ShowWindow

        /// <summary>
        /// Displays content in a window
        /// </summary>
        /// <param name="windowTitle">Title text shown in window</param>
        /// <param name="windowContents">Contents of the window</param>        
        /// <param name="isModal">Determines wheter the window is modal or not</param>
        /// <param name="onClosingHandler">Event handler invoked when window is closing, and can be handled to cancel window closure</param>
        /// <param name="windowType">The type of the window</param>
        /// <param name="onClosedHandler">Event handler invoked when window is closed</param>
        /// <param name="top">The distance from the top of the application at which to position the window</param>
        /// <param name="left">The distance from the left of the application at which to position the window</param>
        /// <returns>The window</returns>
        public object ShowWindow(string windowTitle, FrameworkElement windowContents, bool isModal = false, 
            EventHandler<CancelEventArgs> onClosingHandler = null, EventHandler onClosedHandler = null, 
            WindowType windowType = WindowType.Floating, double? top = null, double? left = null)            
        {                        
            if (windowContents == null)
                throw new ArgumentNullException("windowContents");

            int hashCode = windowContents.GetHashCode();
            FloatingWindow floatingWindow = null;
            if (!m_FloatingWindows.TryGetValue(hashCode, out floatingWindow))
            {
                // not existing yet
                floatingWindow = new FloatingWindow()
                {
                    Title = windowTitle ?? string.Empty,
                };

                switch (windowType)
                {
                    case WindowType.Floating:
                if (FloatingWindowStyle != null)
                    floatingWindow.Style = FloatingWindowStyle;
                        break;
                    case WindowType.DesignTimeFloating:
                        if (DesignTimeWindowStyle != null)
                            floatingWindow.Style = DesignTimeWindowStyle;
                        else if (FloatingWindowStyle != null) // fallback to FloatingWindowStyle
                            floatingWindow.Style = FloatingWindowStyle;
                        break;
                }

                floatingWindow.Closed += (o, e) =>
                {
                    if (onClosedHandler != null)
                        onClosedHandler.Invoke(o, e);

                    m_FloatingWindows.Remove(hashCode);

                    if (floatingWindow != null)
                        floatingWindow.Content = null;
                };

                if (onClosingHandler != null)
                    floatingWindow.Closing += onClosingHandler;
                floatingWindow.Content = windowContents;
                m_FloatingWindows.Add(hashCode, floatingWindow);
            }


            if (top != null)
                floatingWindow.VerticalOffset = (double)top;

            if (left != null)
                floatingWindow.HorizontalOffset = (double)left;

            floatingWindow.Show(isModal);

            return floatingWindow;
        }
开发者ID:konglingjie,项目名称:arcgis-viewer-silverlight,代码行数:71,代码来源:WindowManager.cs

示例8: IceTabPageDCCFile

        public IceTabPageDCCFile(WindowType windowType, string sCaption, FormMain parent)
            : base(windowType, sCaption, parent)
        {
            InitializeComponent();
            this._parent = parent;

            dccFiles = new List<DccFileStruct>();
        }
开发者ID:nicholatian,项目名称:monody,代码行数:8,代码来源:IceTabPageDCCFile.cs

示例9: OpenBugGUI

    public void OpenBugGUI()
    {
        _windowType = WindowType.BugWindow;
        _popUpError = true;

        if (GuiAllowScreenshot)
            _takeScreenshot = true;
    }
开发者ID:volkanb,项目名称:Vampire,代码行数:8,代码来源:GA_Gui.cs

示例10: MakeLowPassKernel

 public static float[] MakeLowPassKernel(double sampleRate, int filterOrder, double cutoffFrequency, WindowType windowType)
 {
     filterOrder |= 1;
       float[] numArray = FilterBuilder.MakeSinc(sampleRate, cutoffFrequency, filterOrder);
       float[] window = FilterBuilder.MakeWindow(windowType, filterOrder);
       FilterBuilder.ApplyWindow(numArray, window);
       FilterBuilder.Normalize(numArray);
       return numArray;
 }
开发者ID:zloiia,项目名称:sdrsrc,代码行数:9,代码来源:FilterBuilder.cs

示例11: Apply

		/**
		 * Returns window value for a given window type, size and position.
		 *
		 * Window is first looked up in cache. If it doesn't exist,
		 * it is generated. The cached value is then returned.
		 *
		 * @param type window function type
		 * @param n sample position in the window
		 * @param N window length
		 * @return window value for n-th sample
		 */
		public static double Apply(WindowType type, int n, int N)
		{
			KeyValuePair<WindowType, int> key = new KeyValuePair<WindowType, int>(type, N);
			
			if (!windowsCache.ContainsKey(key))
				CreateWindow(key);
			
			return windowsCache[key][n];
		}
开发者ID:khairy-mohamed,项目名称:FindSimilar,代码行数:20,代码来源:Window.cs

示例12: Window

        public Window(Context ctx, WindowType type = WindowType.SCREEN_APPLICATION_WINDOW)
        {
            _context = ctx;

            if (type == WindowType.SCREEN_APPLICATION_WINDOW)
                this.CreateWindow();
            else
                this.CreateWindowType(type);
        }
开发者ID:gatm50,项目名称:monoberry,代码行数:9,代码来源:Window.cs

示例13: RacerDetails

        private RacerDetails(WindowType type)
        {
            InitializeComponent();
            
            _type = type;

            foreach(string rClass in DataManager.Settings.Classes)
            {
                cboClass.Items.Add(rClass);
            }
        }
开发者ID:madfrog54321,项目名称:Timer,代码行数:11,代码来源:RacerDetails.xaml.cs

示例14: MakeBandPassKernel

 public static float[] MakeBandPassKernel(double sampleRate, int filterOrder, double cutoff1, double cutoff2, WindowType windowType)
 {
     double cutoffFrequency = (cutoff2 - cutoff1) / 2.0;
       double num1 = 2.0 * Math.PI * (cutoff2 - cutoffFrequency) / sampleRate;
       float[] numArray = FilterBuilder.MakeLowPassKernel(sampleRate, filterOrder, cutoffFrequency, windowType);
       for (int index = 0; index < numArray.Length; ++index)
       {
     int num2 = index - filterOrder / 2;
     numArray[index] *= (float) (2.0 * Math.Cos(num1 * (double) num2));
       }
       return numArray;
 }
开发者ID:zloiia,项目名称:sdrsrc,代码行数:12,代码来源:FilterBuilder.cs

示例15: Window

        public Window(int width, int height, string title, WindowType type, int display, bool visible)
        {
            NativeWindow = new NativeWindow(width, height, title, GameWindowFlags.Default, GraphicsMode.Default, DisplayDevice.GetDisplay((DisplayIndex)display));
            NativeWindow.Closing += WindowClosing;
            NativeWindow.Resize += WindowResize;

            Keyboard = new Keyboard(this);
            Mouse = new Mouse(this);

            Type = type;
            Visible = visible;
        }
开发者ID:killowatt,项目名称:Dunamis,代码行数:12,代码来源:Window.cs


注:本文中的WindowType类示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。