Skip to content

Commit

Permalink
Update text in About window
Browse files Browse the repository at this point in the history
- Add licensing information text
- Add attribution texts for open source libraries being used
  • Loading branch information
kvakulo committed Sep 2, 2014
1 parent eeeac9a commit fab8fe7
Show file tree
Hide file tree
Showing 2 changed files with 53 additions and 10 deletions.
54 changes: 48 additions & 6 deletions Switcheroo/AboutWindow.xaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,24 +3,66 @@
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
Title="About Switcheroo"
WindowStartupLocation="CenterScreen"
ShowInTaskbar="False" SizeToContent="WidthAndHeight" ResizeMode="NoResize">
<StackPanel Margin="10">
<TextBlock >
ShowInTaskbar="False"
SizeToContent="Height"
ResizeMode="NoResize"
Width="400">
<StackPanel Margin="10">
<ScrollViewer Height="250">
<TextBlock TextWrapping="Wrap" Margin="0,0,10,0" Padding="0,0,0,30">
<Bold>Switcheroo</Bold>
<LineBreak/>
<Italic>The humble incremental-search task switcher for Windows</Italic>
<LineBreak/>
<Hyperlink RequestNavigate="HandleRequestNavigate" NavigateUri="http://www.switcheroo.io">www.switcheroo.io</Hyperlink>
<LineBreak/>
Version: <Span Name="VersionNumber"></Span>
<LineBreak/>
Version: <Span Name="VersionNumber"></Span>
<LineBreak/>
<LineBreak/>
© Copyright 2014 Regin Larsen
<LineBreak/>
© Copyright 2009, 2010 James Sulak
<LineBreak />
<LineBreak />
<Hyperlink RequestNavigate="HandleRequestNavigate" Name="hl" NavigateUri="http://www.switcheroo.io">www.switcheroo.io</Hyperlink>
</TextBlock>
Switcheroo is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
<LineBreak />
<LineBreak />
Switcheroo is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
<LineBreak />
<LineBreak />
You should have received a copy of the GNU General Public License
along with Switcheroo. If not, see
<Hyperlink RequestNavigate="HandleRequestNavigate" NavigateUri="http://www.gnu.org/licenses/">www.gnu.org/licenses/</Hyperlink>
<LineBreak />
<LineBreak />
Switcheroo makes use of these great open source projects:
<LineBreak />
<LineBreak />
<Bold>Managed Windows API</Bold>
<LineBreak />
Copyright © 2006 Michael Schier
<LineBreak />
GNU Lesser General Public License (LGPL)
<Hyperlink RequestNavigate="HandleRequestNavigate" NavigateUri="http://mwinapi.sourceforge.net/">mwinapi.sourceforge.net</Hyperlink>
<LineBreak />
<LineBreak />
<Bold>PortableSettingsProvider</Bold>
<LineBreak />
Copyright © crdx
<LineBreak />
The MIT License (MIT)
<LineBreak />
<Hyperlink RequestNavigate="HandleRequestNavigate" NavigateUri="https://github.com/crdx/PortableSettingsProvider">github.com/crdx/PortableSettingsProvider</Hyperlink>
</TextBlock>
</ScrollViewer>

<Grid HorizontalAlignment="Center" Margin="0,10,0,0">
<Button Name="Ok" Width="60" Click="Ok_Click" IsDefault="True">OK</Button>
</Grid>
Expand Down
9 changes: 5 additions & 4 deletions Switcheroo/AboutWindow.xaml.cs
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@
using System.Reflection;
using System.Windows;
using System.Diagnostics;
using System.Windows.Documents;

namespace Switcheroo
{
Expand All @@ -34,10 +35,10 @@ public AboutWindow()

void HandleRequestNavigate(object sender, RoutedEventArgs e)
{
string navigateUri = hl.NavigateUri.ToString();
// if the URI somehow came from an untrusted source, make sure to
// validate it before calling Process.Start(), e.g. check to see
// the scheme is HTTP, etc.
var hyperlink = e.OriginalSource as Hyperlink;
if (hyperlink == null) return;

var navigateUri = hyperlink.NavigateUri.ToString();
Process.Start(new ProcessStartInfo(navigateUri));
e.Handled = true;
}
Expand Down

0 comments on commit fab8fe7

Please sign in to comment.