1 // OpenTween - Client of Twitter
2 // Copyright (c) 2007-2011 kiri_feather (@kiri_feather) <kiri.feather@gmail.com>
3 // (c) 2008-2011 Moz (@syo68k)
4 // (c) 2008-2011 takeshik (@takeshik) <http://www.takeshik.org/>
5 // (c) 2010-2011 anis774 (@anis774) <http://d.hatena.ne.jp/anis774/>
6 // (c) 2010-2011 fantasticswallow (@f_swallow) <http://twitter.com/f_swallow>
7 // (c) 2011 kim_upsilon (@kim_upsilon) <https://upsilo.net/~upsilon/>
8 // All rights reserved.
10 // This file is part of OpenTween.
12 // This program is free software; you can redistribute it and/or modify it
13 // under the terms of the GNU General Public License as published by the Free
14 // Software Foundation; either version 3 of the License, or (at your option)
17 // This program is distributed in the hope that it will be useful, but
18 // WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
19 // or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
22 // You should have received a copy of the GNU General Public License along
23 // with this program. If not, see <http://www.gnu.org/licenses/>, or write to
24 // the Free Software Foundation, Inc., 51 Franklin Street - Fifth Floor,
25 // Boston, MA 02110-1301, USA.
30 using System.Collections.Generic;
33 using System.Xml.Serialization;
34 using OpenTween.Models;
38 public class SettingTabs : SettingBase<SettingTabs>
41 public static SettingTabs Load()
45 => SaveSettings(this);
48 => this.Tabs = new List<SettingTabItem>();
51 public List<SettingTabItem> Tabs;
54 public class SettingTabItem
56 /// <summary>タブの表示名</summary>
57 public string TabName { get; set; } = "";
59 /// <summary>タブの種類</summary>
60 public MyCommon.TabUsageType TabType { get; set; }
62 /// <summary>未読管理を有効にする</summary>
63 public bool UnreadManage { get; set; }
65 /// <summary>タブを保護する</summary>
66 [XmlElement(ElementName = "Locked")] // v1.0.5で「タブを固定(Locked)」から「タブを保護(Protected)」に名称変更
67 public bool Protected { get; set; }
69 /// <summary>新着通知表示を有効にする</summary>
70 public bool Notify { get; set; }
72 /// <summary>通知音</summary>
73 public string SoundFile { get; set; } = "";
76 /// 振り分けルール (<see cref="MyCommon.TabUsageType.UserDefined"/> で使用)
78 public PostFilterRule[] FilterArray { get; set; } = Array.Empty<PostFilterRule>();
81 /// 表示するユーザーのスクリーンネーム (<see cref="MyCommon.TabUsageType.UserTimeline"/> で使用)
83 public string? User { get; set; }
86 /// 検索文字列 (<see cref="MyCommon.TabUsageType.PublicSearch"/> で使用)
88 public string SearchWords { get; set; } = "";
91 /// 検索対象の言語 (<see cref="MyCommon.TabUsageType.PublicSearch"/> で使用)
93 public string SearchLang { get; set; } = "";
96 /// 表示するリスト (<see cref="MyCommon.TabUsageType.Lists"/> で使用)
98 public ListElement? ListInfo { get; set; }