本文整理汇总了C#中Dialog.SetupUi方法的典型用法代码示例。如果您正苦于以下问题:C# Dialog.SetupUi方法的具体用法?C# Dialog.SetupUi怎么用?C# Dialog.SetupUi使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Dialog
的用法示例。
在下文中一共展示了Dialog.SetupUi方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: MainForm
public MainForm (string[] args) : base ()
{
main = new Dialog ();
main.SetupUi (this);
// create the checkbox mapping
backend_checkboxes = new Dictionary<string, QCheckBox> (20);
backend_checkboxes ["Files"] = main.filesBackend;
backend_checkboxes ["Locate"] = main.locateBackend;
backend_checkboxes ["KMail"] = main.kmailBackend;
backend_checkboxes ["EvolutionMail"] = main.evoBackend;
backend_checkboxes ["Thunderbird"] = main.tbirdBackend;
backend_checkboxes ["Kopete"] = main.kopeteBackend;
backend_checkboxes ["Konversation"] = main.konvBackend;
backend_checkboxes ["Pidgin"] = main.pidginBackend;
backend_checkboxes ["Empathy"] = main.empathyBackend;
backend_checkboxes ["KonquerorHistory"] = main.konqBackend;
backend_checkboxes ["KonqBookmark"] = main.kBookmarkBackend;
backend_checkboxes ["Opera"] = main.operaBackend;
backend_checkboxes ["IndexingService"] = main.ffBackend;
backend_checkboxes ["KOrganizer"] = main.korgBackend;
backend_checkboxes ["KNotes"] = main.knotesBackend;
backend_checkboxes ["KAddressBook"] = main.kaddrbookBackend;
backend_checkboxes ["Tomboy"] = main.tomboyBackend;
backend_checkboxes ["Labyrinth"] = main.labyrinthBackend;
backend_checkboxes ["EvolutionDataServer"] = main.edsBackend;
backend_checkboxes ["Akregator"] = main.akregatorBackend;
backend_checkboxes ["Blam"] = main.blamBackend;
backend_checkboxes ["Liferea"] = main.lifereaBackend;
backend_checkboxes ["documentation"] = main.docBackend;
backend_checkboxes ["applications"] = main.appBackend;
backend_checkboxes ["manpages"] = main.manpagesBackend;
backend_checkboxes ["monodoc"] = main.monodocBackend;
backend_checkboxes ["GMailSearch"] = main.gmailLiveBackend;
Connect (main.CancelButton, SIGNAL ("clicked()"), qApp, SLOT ("quit()"));
Connect (main.OkButton, SIGNAL ("clicked()"), this, SLOT ("saveSettings()"));
Connect (main.RootAddButton, SIGNAL ("clicked()"), this, SLOT ("showDirChooser()"));
Connect (main.RootRemoveButton, SIGNAL ("clicked()"), this, SLOT ("removeChosenDir()"));
Connect (main.ExcludeDirAddButton, SIGNAL ("clicked()"), this, SLOT ("addExcludeDir()"));
Connect (main.ExcludeDirRemoveButton, SIGNAL ("clicked()"), this, SLOT ("removeExcludeDir()"));
Connect (main.PatternAdd, SIGNAL ("clicked()"), this, SLOT ("addNamePattern()"));
Connect (main.PatternRemove, SIGNAL ("clicked()"), this, SLOT ("removeNamePattern()"));
Connect (main.MailFolderAdd, SIGNAL ("clicked()"), this, SLOT ("addFolderPattern()"));
Connect (main.MailFolderRemove, SIGNAL ("clicked()"), this, SLOT ("removeFolderPattern()"));
Connect (main.IsGoogleAppsAccount, SIGNAL ("stateChanged(int)"), this, SLOT ("isGoogleAppsToggled(int)"));
LoadSettings ();
if (args.Length == 0)
return;
if (Array.IndexOf (args, "--indexing") != -1)
main.TabWidget.SetCurrentWidget (main.IndexingTab);
else if (Array.IndexOf (args, "--backends") != -1)
main.TabWidget.SetCurrentWidget (main.BackendsTab);
else if (Array.IndexOf (args, "--networking") != -1)
main.TabWidget.SetCurrentWidget (main.NetworkingTab);
else if (Array.IndexOf (args, "--google") != -1)
main.TabWidget.SetCurrentWidget (main.GoogleTab);
else
main.TabWidget.SetCurrentWidget (main.GeneralTab);
}