示例#1
0
 public TabWindow(string channel, MainWindow mainWindow, int index, SolidColorBrush background)
 {
     Index = index;
     UserList = new UserList();
     Channel = channel;
     Header = Channel;
     Rtb = new RichTextBox();
     Rtb.FontSize = 15;
     Main = mainWindow;
     Rtb.Background = Brushes.Black;
     Rtb.VerticalScrollBarVisibility = ScrollBarVisibility.Visible;
     Rtb.IsReadOnly = true;
     Rtb.IsDocumentEnabled = true;
     Rtb.Background = background;
     this.AddChild(Rtb);
     //Timer = new DispatcherTimer();
     //Timer.Interval = TimeSpan.FromMilliseconds(200);
     //Timer.Tick += new EventHandler(UpdateText_Tick);
     EveryInput = new Dictionary<Paragraph, string>();
     //Join();
 }
示例#2
0
 public MainWindow()
 {
     InitializeComponent();
     EmptyUserList = new UserList();
     Down.Push("");
     EveryInput = new Dictionary<Paragraph, string>();
     EmoteList = new Emotes();
     image_test.Width = 0;
     Image_test = image_test;
     Timer = new DispatcherTimer();
     Timer.Interval = TimeSpan.FromMilliseconds(200);
     Timer.Tick += new EventHandler(UpdateText_Tick);
     //Timer.Start();
     userList = new UserList();
     Text_UserList.Document.PageWidth = 1000;
     isolatedStorage = IsolatedStorageFile.GetUserStoreForAssembly();
     Tabs = new List<TabWindow>();
     if (isolatedStorage.FileExists(isoFile))
     {
         RememberMe.IsChecked = true;
         using (StreamReader sr = new StreamReader(new IsolatedStorageFileStream(isoFile, FileMode.Open, isolatedStorage)))
         {
             text_user.Text = sr.ReadLine();
             text_chan.Text = sr.ReadLine().Replace("#", "");
             text_pass.Password = sr.ReadLine();
         }
     }
     LoadDefaults();
 }
示例#3
0
 public void UpdateSelected(UserList temp, int tabIndex = 0)
 {
     CurrentTab = tabIndex;
     userList = temp;
     updateUserList();
 }