Skip to content

Commit

Permalink
Tooltip
Browse files Browse the repository at this point in the history
+ Added ToolTip - additional field which will display in popup list
(have no affect on posting message)
+ Increased Width of Main window
  • Loading branch information
[email protected] committed Jan 17, 2017
1 parent 8ac30bb commit de724d3
Show file tree
Hide file tree
Showing 5 changed files with 20 additions and 5 deletions.
16 changes: 15 additions & 1 deletion DiscordAnnouncer/Base/ChannelItem.cs
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,8 @@ public string Type
#endregion EndOf-Type




#region ProductName
protected string _productName;
[DataMember]
Expand Down Expand Up @@ -73,7 +75,19 @@ public ulong ChannelId
}
#endregion EndOf-ChannelId

public string Name => $"{ProductName} [{Type}]";
public string Name => $"{ProductName} [{Type}] ({ToolTip})";

#region ToolTip
protected string _toolTip;
[DataMember]
public string ToolTip
{
get { return _toolTip; }
set { _toolTip = value; OnPropertyChanged(); }
}
#endregion EndOf-ToolTip



#region INotifyPropertyChanged
public event PropertyChangedEventHandler PropertyChanged;
Expand Down
2 changes: 1 addition & 1 deletion DiscordAnnouncer/MainWindow.xaml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
xmlns:local="clr-namespace:Alisha.DiscordAnnouncer"
DataContext="{Binding RelativeSource={RelativeSource Self}}"
mc:Ignorable="d"
Title="Alisha's Discord Announcer" Height="512" Width="889" WindowStartupLocation="CenterScreen" Icon="Properties/Resources/icon.ico">
Title="Alisha's Discord Announcer" Height="522" Width="1129" WindowStartupLocation="CenterScreen" Icon="Properties/Resources/icon.ico">
<DockPanel>
<DockPanel Dock="Bottom" Margin="4,3">
<Button DockPanel.Dock="Left" Click="OnSaveClick" HorizontalAlignment="Right">Save Settings</Button>
Expand Down
2 changes: 1 addition & 1 deletion DiscordAnnouncer/MainWindow.xaml.cs
Original file line number Diff line number Diff line change
Expand Up @@ -151,7 +151,7 @@ private void SelectedChannelChanged(object sender, SelectionChangedEventArgs e)
Settings.SelectedChannelItem = channelItem;
if (channelData == null) return;

txtInfo.Text = $"[{channelData.Id}] #{channelData.Name}";
txtInfo.Text = $"[{channelData.Id}] #{channelData.Name} ({channelItem.ToolTip})";
}

Save();
Expand Down
4 changes: 2 additions & 2 deletions DiscordAnnouncer/Properties/AssemblyInfo.cs
Original file line number Diff line number Diff line change
Expand Up @@ -34,5 +34,5 @@
//
// Можно задать все значения или принять номер построения и номер редакции по умолчанию,
// используя "*", как показано ниже:
[assembly: AssemblyVersion("1.1.16.0144")]
[assembly: AssemblyInformationalVersion("Build date: 2017-01-16 01:44:44; Revision date: 2017-01-16 01:44:42; Revision(s) in working copy: 1:16.")]
[assembly: AssemblyVersion("1.1.18.0207")]
[assembly: AssemblyInformationalVersion("Build date: 2017-01-18 02:07:11; Revision date: 2017-01-18 02:07:08; Revision(s) in working copy: 1:18.")]
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,7 @@ But you can use it for other purpose as well :)
4. **ChannelId** - To which channel message be posted
5. **Prefix**- line formating to be used to make prefix of message
6. **Name** - use for display in Posting tab, not editable
7. **ToolTip** - used for display in Posting tab, have no affect on posting message

![GUI Screenshot - ServerData](https://raw.githubusercontent.com/alishahb/DiscordAnnouncer/master/PICS/DiscordAnnouncer-ServerData.png)

Expand Down

0 comments on commit de724d3

Please sign in to comment.