Browse Source
git-svn-id: svn://svn.sharpdevelop.net/sharpdevelop/trunk@6165 1ccf3a8d-04fe-1044-b7c0-cef0b8235c61pull/1/head
8 changed files with 161 additions and 96 deletions
@ -0,0 +1,38 @@
@@ -0,0 +1,38 @@
|
||||
<UserControl x:Class="ICSharpCode.SharpDevelop.Refactoring.ContextActionsHeaderedControl" |
||||
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" |
||||
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" |
||||
xmlns:local="clr-namespace:ICSharpCode.SharpDevelop.Refactoring" |
||||
xmlns:aero="clr-namespace:Microsoft.Windows.Themes;assembly=PresentationFramework.Aero"> |
||||
|
||||
<UserControl.Resources> |
||||
<SolidColorBrush x:Key="OuterBorderBrush" Color="#436C82"></SolidColorBrush> |
||||
</UserControl.Resources> |
||||
|
||||
<Grid Background="Transparent"> |
||||
<Grid.RowDefinitions> |
||||
<RowDefinition></RowDefinition> |
||||
<RowDefinition></RowDefinition> |
||||
</Grid.RowDefinitions> |
||||
<Grid.ColumnDefinitions> |
||||
<ColumnDefinition></ColumnDefinition> |
||||
</Grid.ColumnDefinitions> |
||||
|
||||
<!-- Header --> |
||||
<Border Grid.Row="0" Grid.Column="0" Padding="4" BorderThickness="1 1 1 0" |
||||
BorderBrush="{StaticResource OuterBorderBrush}" HorizontalAlignment="Left"> |
||||
<Border.Background> |
||||
<LinearGradientBrush StartPoint="0,0" EndPoint="0,1"> |
||||
<GradientStop Color="#D6E9FF" Offset="0"/> |
||||
<GradientStop Color="#A3CEFF" Offset="0.5"/> |
||||
</LinearGradientBrush> |
||||
</Border.Background> |
||||
<StackPanel Orientation="Horizontal"> |
||||
<Image Source="{Binding Image}"></Image> |
||||
<TextBlock Text="{Binding Title}"></TextBlock> |
||||
</StackPanel> |
||||
</Border> |
||||
|
||||
<!-- Content - TreeView --> |
||||
<local:ContextActionsControl x:Name="ActionsTreeView" Grid.Row="1" Grid.Column="0" DataContext="{Binding Actions}"></local:ContextActionsControl> |
||||
</Grid> |
||||
</UserControl> |
||||
@ -0,0 +1,41 @@
@@ -0,0 +1,41 @@
|
||||
// <file>
|
||||
// <copyright see="prj:///doc/copyright.txt"/>
|
||||
// <license see="prj:///doc/license.txt"/>
|
||||
// <owner name="Martin Konicek" email="martin.konicek@gmail.com"/>
|
||||
// <version>$Revision: $</version>
|
||||
// </file>
|
||||
using System; |
||||
using System.Collections.Generic; |
||||
using System.Text; |
||||
using System.Windows; |
||||
using System.Windows.Controls; |
||||
using System.Windows.Data; |
||||
using System.Windows.Documents; |
||||
using System.Windows.Input; |
||||
using System.Windows.Media; |
||||
|
||||
namespace ICSharpCode.SharpDevelop.Refactoring |
||||
{ |
||||
/// <summary>
|
||||
/// Interaction logic for ContextActionsHeaderedControl.xaml
|
||||
/// </summary>
|
||||
public partial class ContextActionsHeaderedControl : UserControl |
||||
{ |
||||
public ContextActionsHeaderedControl() |
||||
{ |
||||
InitializeComponent(); |
||||
} |
||||
|
||||
public event EventHandler ActionExecuted |
||||
{ |
||||
add { this.ActionsTreeView.ActionExecuted += value; } |
||||
remove { this.ActionsTreeView.ActionExecuted -= value; } |
||||
} |
||||
|
||||
public new void Focus() |
||||
{ |
||||
if (this.ActionsTreeView != null) |
||||
this.ActionsTreeView.Focus(); |
||||
} |
||||
} |
||||
} |
||||
Loading…
Reference in new issue