コード例 #1
0
ファイル: Class1.cs プロジェクト: Phoshi/TWiME-Layouts
        public SquaresLayout(List<Window> windowList, Rectangle area, TagScreen parent)
        {
            _windowList = windowList;
            _owned = area;
            _parent = parent;

            splitter =
                float.Parse(Manager.settings.ReadSettingOrDefault(0.5f, parent.parent.Screen.DeviceName.Replace(".", ""),
                                                                  parent.tag.ToString(), "Splitter"));
            vsplitter =
                float.Parse(Manager.settings.ReadSettingOrDefault(0.5f, parent.parent.Screen.DeviceName.Replace(".", ""),
                                                                  parent.tag.ToString(), "VSplitter"));
        }
コード例 #2
0
ファイル: Monitor.cs プロジェクト: Phoshi/TWiME
 private void createTagScreens()
 {
     for (int i = 0; i < tagScreens.Length; i++) {
         tagScreens[i] = new TagScreen(this, i);
     }
 }
コード例 #3
0
ファイル: TagScreen.cs プロジェクト: Phoshi/TWiME
 public void Disable(TagScreen swappingWith)
 {
     foreach (Window window in windows) {
         if (!swappingWith.windows.Contains(window)) {
             window.Visible = false;
         }
     }
 }
コード例 #4
0
ファイル: Monitor.cs プロジェクト: Phoshi/TWiME
 public void ChangeNumberOfTagScreens(int newNumber)
 {
     if (newNumber < 1) {
         return;
     }
     if (IsTagEnabled(newNumber)) {
         SetTagState(0, true);
     }
     TagScreen[] newTS = new TagScreen[newNumber];
     if (tagScreens.Length > newNumber) {
         for (int i = newNumber; i < tagScreens.Length; i++) {
             tagScreens[i].Disown();
         }
         Array.Copy(tagScreens, newTS, newNumber);
     }
     else {
         Array.Copy(tagScreens, newTS, newNumber - (newNumber - tagScreens.Length));
     }
     for (int i = tagScreens.Length; i < newTS.Length; i++) {
         newTS[i] = new TagScreen(this, i);
     }
     tagScreens = newTS;
     Manager.settings.AddSetting(newNumber.ToString(), SafeName, "NumberOfTags");
 }