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


C# FileChooserDialog.HideAll方法代码示例

本文整理汇总了C#中Gtk.FileChooserDialog.HideAll方法的典型用法代码示例。如果您正苦于以下问题:C# FileChooserDialog.HideAll方法的具体用法?C# FileChooserDialog.HideAll怎么用?C# FileChooserDialog.HideAll使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在Gtk.FileChooserDialog的用法示例。


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

示例1: OnButton1Clicked

 protected void OnButton1Clicked(object sender, EventArgs e)
 {
     FileChooserDialog Dlg;
     Dlg = new FileChooserDialog ("Directorio Inicial", null, FileChooserAction.SelectFolder, Stock.Open, ResponseType.Ok, Stock.Cancel, ResponseType.Cancel);
     Dlg.ShowAll ();
     if (Dlg.Run () == (int)ResponseType.Ok) {
         E1.Text = Dlg.Filename;
     }
     Dlg.HideAll ();
     Dlg.Destroy ();
 }
开发者ID:ivajo26,项目名称:EjerciciosCSharp,代码行数:11,代码来源:MainWindow.cs

示例2: OnCreateButtonClicked

        protected virtual void OnCreateButtonClicked(object sender, System.EventArgs e)
        {
            savePathChooser = new FileChooserDialog(_("Save Torrent As..."), this, FileChooserAction.Save, Gtk.Stock.Cancel, ResponseType.Cancel, Gtk.Stock.Save, ResponseType.Accept);
            ResponseType result = (ResponseType) savePathChooser.Run();
            if(result == ResponseType.Accept){
                savePathChooser.HideAll();
                createTorrent();
            }

            if(result == ResponseType.Cancel || result == ResponseType.DeleteEvent){
                savePathChooser.Destroy();
                //createTorrentDialog.Destroy();
                return;
            }
        }
开发者ID:ArsenShnurkov,项目名称:monsoon,代码行数:15,代码来源:CreateTorrentDialog.cs

示例3: openLibFile

 private void openLibFile(object s, EventArgs e)
 {
     FileChooserDialog fcd = new FileChooserDialog("Open Library File...", this, FileChooserAction.Open);
     fcd.TransientFor = this;
     fcd.AddButton(Stock.Cancel, ResponseType.Cancel);
     fcd.AddButton(Stock.Ok, ResponseType.Ok);
     FileFilter ff = new FileFilter();
     ff.Name = "Dynamic Link Library (.dll,.exe)";
     ff.AddPattern(@"*.dll");
     ff.AddPattern(@"*.exe");
     fcd.AddFilter(ff);
     int result = fcd.Run();
     fcd.HideAll();
     if(result == (int)ResponseType.Ok) {
         ss.ConnectAlgorithmLibrary(fcd.Filename);
     }
     fcd.Dispose();
 }
开发者ID:KommuSoft,项目名称:ParVis,代码行数:18,代码来源:DisplayWindow.cs

示例4: openConfigFile

 private void openConfigFile(object s, EventArgs e)
 {
     FileChooserDialog fcd = new FileChooserDialog("Open Config File...", this, FileChooserAction.Open);
     fcd.TransientFor = this;
     fcd.AddButton(Stock.Cancel, ResponseType.Cancel);
     fcd.AddButton(Stock.Ok, ResponseType.Ok);
     FileFilter ff = new FileFilter();
     ff.Name = "Config file (.xml)";
     ff.AddMimeType("text/xml");
     ff.AddMimeType("application/xml");
     fcd.AddFilter(ff);
     int result = fcd.Run();
     fcd.HideAll();
     if(result == (int)ResponseType.Ok) {
         try {
             ss.ReadConfigFile(fcd.Filename);
             this.sr = ss.Simulator.CollectResults();
             this.bs.SetMinCurrentMax(1, 1, this.sr.ChapterCount);
             this.bpsp.SimulatorResult = sr;
         }
         catch(Exception ex) {
             Console.Error.WriteLine(ex);
             MessageDialog md = new MessageDialog(this, DialogFlags.DestroyWithParent, MessageType.Error, ButtonsType.Ok, true, ex.Message);
             md.Run();
             md.Destroy();
         }
         this.bpsp.Reload();
     }
     fcd.Dispose();
 }
开发者ID:KommuSoft,项目名称:ParVis,代码行数:30,代码来源:DisplayWindow.cs

示例5: tool_saveaspdf

 private void tool_saveaspdf(object sender, EventArgs e)
 {
     using(FileChooserDialog fcd_pdf = new FileChooserDialog("PDF File",this,FileChooserAction.Save)) {
         FileFilter ff = new FileFilter();
         ff.AddPattern("*.pdf");
         ff.Name = "PDF file";
         fcd_pdf.AddFilter(ff);
         fcd_pdf.AddButton("OK",ResponseType.Ok);
         int result = fcd_pdf.Run();
         if(result == (int) ResponseType.Ok) {
             PointD siz = this.sketchpad.MeasureSize();
             using(PdfSurface pdfs = new PdfSurface(fcd_pdf.Filename,siz.X,siz.Y)) {
                 using(Context ctx = new Context(pdfs)) {
                     this.sketchpad.PaintContext(ctx,(int) Math.Ceiling(siz.X),(int) Math.Ceiling(siz.Y));
                 }
             }
         }
         fcd_pdf.HideAll();
     }
 }
开发者ID:KommuSoft,项目名称:CplKul2012,代码行数:20,代码来源:TopWindow.cs

示例6: window_Shown

        void window_Shown(object sender, EventArgs e)
        {
            FileChooserDialog dialog = new FileChooserDialog("Choose a directory", (Window)sender, FileChooserAction.SelectFolder);

            Button button = (Button)dialog.AddButton("OK", ResponseType.Ok);
            dialog.TransientFor = (Window)sender;

            ResponseType result = (ResponseType)dialog.Run();
            dialog.HideAll();

            if (result == ResponseType.Ok)
            {
                RunDirectoryScan(dialog.Filename);
            }
        }
开发者ID:joncham,项目名称:NDirStat,代码行数:15,代码来源:MainWindow.cs


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