3 changed files with 221 additions and 159 deletions
@ -0,0 +1,57 @@ |
|||||||
|
// Copyright (c) AlphaSierraPapa for the SharpDevelop Team (for details please see \doc\copyright.txt)
|
||||||
|
// This code is distributed under the GNU LGPL (for details please see \doc\license.txt)
|
||||||
|
|
||||||
|
using System; |
||||||
|
using System.Windows; |
||||||
|
using System.Windows.Controls; |
||||||
|
|
||||||
|
using ICSharpCode.Core; |
||||||
|
using ICSharpCode.SharpDevelop; |
||||||
|
using ICSharpCode.SharpDevelop.Gui; |
||||||
|
using ICSharpCode.WpfDesign.Designer.ThumbnailView; |
||||||
|
|
||||||
|
namespace ICSharpCode.WpfDesign.AddIn |
||||||
|
{ |
||||||
|
|
||||||
|
public class ThumbnailViewPad : AbstractPadContent |
||||||
|
{ |
||||||
|
ContentPresenter contentControl = new ContentPresenter(); |
||||||
|
|
||||||
|
ThumbnailView thumbnailView = new ThumbnailView(); |
||||||
|
|
||||||
|
TextBlock notAvailableTextBlock = new TextBlock { |
||||||
|
Text = StringParser.Parse("${res:ICSharpCode.SharpDevelop.Gui.OutlinePad.NotAvailable}"), |
||||||
|
TextWrapping = TextWrapping.Wrap |
||||||
|
}; |
||||||
|
|
||||||
|
public ThumbnailViewPad() |
||||||
|
{ |
||||||
|
WorkbenchSingleton.Workbench.ActiveViewContentChanged += WorkbenchActiveViewContentChanged; |
||||||
|
WorkbenchActiveViewContentChanged(null, null); |
||||||
|
} |
||||||
|
|
||||||
|
void WorkbenchActiveViewContentChanged(object sender, EventArgs e) |
||||||
|
{ |
||||||
|
WpfViewContent wpfView = WorkbenchSingleton.Workbench.ActiveViewContent as WpfViewContent; |
||||||
|
if (wpfView != null) |
||||||
|
{ |
||||||
|
thumbnailView.DesignSurface = wpfView.DesignSurface; |
||||||
|
contentControl.SetContent(thumbnailView); |
||||||
|
} |
||||||
|
else |
||||||
|
{ |
||||||
|
|
||||||
|
contentControl.SetContent(notAvailableTextBlock); |
||||||
|
} |
||||||
|
} |
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// The <see cref="System.Windows.Forms.Control"/> representing the pad
|
||||||
|
/// </summary>
|
||||||
|
public override object Control { |
||||||
|
get { |
||||||
|
return contentControl; |
||||||
|
} |
||||||
|
} |
||||||
|
} |
||||||
|
} |
||||||
@ -1,160 +1,157 @@ |
|||||||
<?xml version="1.0" encoding="utf-8"?> |
<?xml version="1.0" encoding="utf-8"?> |
||||||
<Project DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003" ToolsVersion="4.0"> |
<Project DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003" ToolsVersion="4.0"> |
||||||
<PropertyGroup> |
<PropertyGroup> |
||||||
<ProjectGuid>{9A9D6FD4-6A2E-455D-ACC3-DDA775FE9865}</ProjectGuid> |
<ProjectGuid>{9A9D6FD4-6A2E-455D-ACC3-DDA775FE9865}</ProjectGuid> |
||||||
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration> |
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration> |
||||||
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform> |
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform> |
||||||
<OutputType>Library</OutputType> |
<OutputType>Library</OutputType> |
||||||
<RootNamespace>ICSharpCode.WpfDesign.AddIn</RootNamespace> |
<RootNamespace>ICSharpCode.WpfDesign.AddIn</RootNamespace> |
||||||
<AssemblyName>ICSharpCode.WpfDesign.AddIn</AssemblyName> |
<AssemblyName>ICSharpCode.WpfDesign.AddIn</AssemblyName> |
||||||
<OutputPath>..\..\..\..\..\AddIns\DisplayBindings\WpfDesign\</OutputPath> |
<OutputPath>..\..\..\..\..\AddIns\DisplayBindings\WpfDesign\</OutputPath> |
||||||
<AllowUnsafeBlocks>False</AllowUnsafeBlocks> |
<AllowUnsafeBlocks>False</AllowUnsafeBlocks> |
||||||
<NoStdLib>False</NoStdLib> |
<NoStdLib>False</NoStdLib> |
||||||
<WarningLevel>4</WarningLevel> |
<WarningLevel>4</WarningLevel> |
||||||
<TreatWarningsAsErrors>false</TreatWarningsAsErrors> |
<TreatWarningsAsErrors>false</TreatWarningsAsErrors> |
||||||
<TargetFrameworkVersion>v4.0</TargetFrameworkVersion> |
<TargetFrameworkVersion>v4.0</TargetFrameworkVersion> |
||||||
<TargetFrameworkProfile> |
<TargetFrameworkProfile> |
||||||
</TargetFrameworkProfile> |
</TargetFrameworkProfile> |
||||||
</PropertyGroup> |
</PropertyGroup> |
||||||
<PropertyGroup Condition=" '$(Configuration)' == 'Debug' "> |
<PropertyGroup Condition=" '$(Configuration)' == 'Debug' "> |
||||||
<DebugSymbols>true</DebugSymbols> |
<DebugSymbols>true</DebugSymbols> |
||||||
<DebugType>Full</DebugType> |
<DebugType>Full</DebugType> |
||||||
<CheckForOverflowUnderflow>True</CheckForOverflowUnderflow> |
<CheckForOverflowUnderflow>True</CheckForOverflowUnderflow> |
||||||
<DefineConstants>DEBUG;TRACE</DefineConstants> |
<DefineConstants>DEBUG;TRACE</DefineConstants> |
||||||
<Optimize>False</Optimize> |
<Optimize>False</Optimize> |
||||||
</PropertyGroup> |
</PropertyGroup> |
||||||
<PropertyGroup Condition=" '$(Configuration)' == 'Release' "> |
<PropertyGroup Condition=" '$(Configuration)' == 'Release' "> |
||||||
<DebugSymbols>False</DebugSymbols> |
<DebugSymbols>False</DebugSymbols> |
||||||
<DebugType>None</DebugType> |
<DebugType>None</DebugType> |
||||||
<CheckForOverflowUnderflow>False</CheckForOverflowUnderflow> |
<CheckForOverflowUnderflow>False</CheckForOverflowUnderflow> |
||||||
<DefineConstants>TRACE</DefineConstants> |
<DefineConstants>TRACE</DefineConstants> |
||||||
</PropertyGroup> |
</PropertyGroup> |
||||||
<PropertyGroup Condition=" '$(Platform)' == 'AnyCPU' "> |
<PropertyGroup Condition=" '$(Platform)' == 'AnyCPU' "> |
||||||
<RegisterForComInterop>False</RegisterForComInterop> |
<RegisterForComInterop>False</RegisterForComInterop> |
||||||
<GenerateSerializationAssemblies>Auto</GenerateSerializationAssemblies> |
<GenerateSerializationAssemblies>Auto</GenerateSerializationAssemblies> |
||||||
<BaseAddress>4194304</BaseAddress> |
<BaseAddress>4194304</BaseAddress> |
||||||
<PlatformTarget>AnyCPU</PlatformTarget> |
<PlatformTarget>AnyCPU</PlatformTarget> |
||||||
<FileAlignment>4096</FileAlignment> |
<FileAlignment>4096</FileAlignment> |
||||||
</PropertyGroup> |
</PropertyGroup> |
||||||
<Import Project="$(MSBuildBinPath)\Microsoft.CSharp.Targets" /> |
<Import Project="$(MSBuildBinPath)\Microsoft.CSharp.Targets" /> |
||||||
<ItemGroup> |
<ItemGroup> |
||||||
<Reference Include="PresentationCore" /> |
<Reference Include="PresentationCore" /> |
||||||
<Reference Include="PresentationFramework" /> |
<Reference Include="PresentationFramework" /> |
||||||
<Reference Include="System" /> |
<Reference Include="System" /> |
||||||
<Reference Include="System.Core"> |
<Reference Include="System.Core"> |
||||||
<RequiredTargetFramework>3.5</RequiredTargetFramework> |
<RequiredTargetFramework>3.5</RequiredTargetFramework> |
||||||
</Reference> |
</Reference> |
||||||
<Reference Include="System.Data" /> |
<Reference Include="System.Data" /> |
||||||
<Reference Include="System.Drawing" /> |
<Reference Include="System.Drawing" /> |
||||||
<Reference Include="System.Windows.Forms" /> |
<Reference Include="System.Windows.Forms" /> |
||||||
<Reference Include="System.Xaml"> |
<Reference Include="System.Xaml"> |
||||||
<RequiredTargetFramework>4.0</RequiredTargetFramework> |
<RequiredTargetFramework>4.0</RequiredTargetFramework> |
||||||
</Reference> |
</Reference> |
||||||
<Reference Include="System.Xml" /> |
<Reference Include="System.Xml" /> |
||||||
<Reference Include="WindowsBase" /> |
<Reference Include="WindowsBase" /> |
||||||
</ItemGroup> |
</ItemGroup> |
||||||
<ItemGroup> |
<ItemGroup> |
||||||
<Resource Include="Images\Icons.32x32.Error.png" /> |
<Resource Include="Images\Icons.32x32.Error.png" /> |
||||||
<None Include="WpfDesign.addin"> |
<None Include="WpfDesign.addin"> |
||||||
<CopyToOutputDirectory>Always</CopyToOutputDirectory> |
<CopyToOutputDirectory>Always</CopyToOutputDirectory> |
||||||
</None> |
</None> |
||||||
<Compile Include="..\..\..\..\Main\GlobalAssemblyInfo.cs"> |
<Compile Include="..\..\..\..\Main\GlobalAssemblyInfo.cs"> |
||||||
<Link>Configuration\GlobalAssemblyInfo.cs</Link> |
<Link>Configuration\GlobalAssemblyInfo.cs</Link> |
||||||
</Compile> |
</Compile> |
||||||
<Compile Include="Configuration\AssemblyInfo.cs" /> |
<Compile Include="Configuration\AssemblyInfo.cs" /> |
||||||
<Compile Include="Src\AbstractEventHandlerService.cs" /> |
<Compile Include="Src\AbstractEventHandlerService.cs" /> |
||||||
<Compile Include="Src\Commands\CutCopyPaste.cs" /> |
<Compile Include="Src\Commands\CutCopyPaste.cs" /> |
||||||
<Compile Include="Src\Commands\Pads.cs" /> |
<Compile Include="Src\Commands\Pads.cs" /> |
||||||
<Compile Include="Src\Commands\Remove.cs" /> |
<Compile Include="Src\Commands\Remove.cs" /> |
||||||
<Compile Include="Src\Commands\UndoRedo.cs" /> |
<Compile Include="Src\Commands\UndoRedo.cs" /> |
||||||
<Compile Include="Src\Commands\ViewXaml.cs" /> |
<Compile Include="Src\Commands\ViewXaml.cs" /> |
||||||
<Compile Include="Src\CSharpEventHandlerService.cs" /> |
<Compile Include="Src\ThumbnailViewPad.cs" /> |
||||||
<Compile Include="Src\FileUriContext.cs" /> |
<Compile Include="Src\CSharpEventHandlerService.cs" /> |
||||||
<Compile Include="Src\IdeChooseClassService.cs" /> |
<Compile Include="Src\FileUriContext.cs" /> |
||||||
<Compile Include="Src\ImageSourceEditor\ChooseImageDialog.xaml.cs"> |
<Compile Include="Src\IdeChooseClassService.cs" /> |
||||||
<DependentUpon>ChooseImageDialog.xaml</DependentUpon> |
<Compile Include="Src\ImageSourceEditor\ChooseImageDialog.xaml.cs"> |
||||||
<SubType>Code</SubType> |
<DependentUpon>ChooseImageDialog.xaml</DependentUpon> |
||||||
</Compile> |
<SubType>Code</SubType> |
||||||
<Compile Include="Src\ImageSourceEditor\ImageSourceEditor.xaml.cs"> |
</Compile> |
||||||
<DependentUpon>ImageSourceEditor.xaml</DependentUpon> |
<Compile Include="Src\ImageSourceEditor\ImageSourceEditor.xaml.cs"> |
||||||
<SubType>Code</SubType> |
<DependentUpon>ImageSourceEditor.xaml</DependentUpon> |
||||||
</Compile> |
<SubType>Code</SubType> |
||||||
<Compile Include="Src\MyTypeFinder.cs" /> |
</Compile> |
||||||
<Compile Include="Src\ObjectEditor.xaml.cs"> |
<Compile Include="Src\MyTypeFinder.cs" /> |
||||||
<DependentUpon>ObjectEditor.xaml</DependentUpon> |
<Compile Include="Src\ObjectEditor.xaml.cs"> |
||||||
</Compile> |
<DependentUpon>ObjectEditor.xaml</DependentUpon> |
||||||
<Compile Include="Src\OutlineViewPad.cs" /> |
</Compile> |
||||||
<Compile Include="Src\ProjectTools.cs" /> |
<Compile Include="Src\OutlineViewPad.cs" /> |
||||||
<Compile Include="Src\PropertyDescriptionService.cs" /> |
<Compile Include="Src\ProjectTools.cs" /> |
||||||
<Compile Include="Src\WpfAndWinFormsTopLevelWindowService.cs" /> |
<Compile Include="Src\PropertyDescriptionService.cs" /> |
||||||
<Compile Include="Src\WpfDisplayBinding.cs" /> |
<Compile Include="Src\WpfAndWinFormsTopLevelWindowService.cs" /> |
||||||
<Compile Include="Src\WpfDocumentError.xaml.cs"> |
<Compile Include="Src\WpfDisplayBinding.cs" /> |
||||||
<DependentUpon>WpfDocumentError.xaml</DependentUpon> |
<Compile Include="Src\WpfDocumentError.xaml.cs"> |
||||||
<SubType>Code</SubType> |
<DependentUpon>WpfDocumentError.xaml</DependentUpon> |
||||||
</Compile> |
<SubType>Code</SubType> |
||||||
<Compile Include="Src\WpfSideTabItem.cs" /> |
</Compile> |
||||||
<Compile Include="Src\WpfToolbox.cs" /> |
<Compile Include="Src\WpfSideTabItem.cs" /> |
||||||
<Compile Include="Src\WpfViewContent.cs" /> |
<Compile Include="Src\WpfToolbox.cs" /> |
||||||
</ItemGroup> |
<Compile Include="Src\WpfViewContent.cs" /> |
||||||
<ItemGroup> |
</ItemGroup> |
||||||
<Page Include="Src\WpfDocumentError.xaml" /> |
<ItemGroup> |
||||||
<ProjectReference Include="..\..\..\..\Main\Base\Project\ICSharpCode.SharpDevelop.csproj"> |
<Page Include="Src\WpfDocumentError.xaml" /> |
||||||
<Project>{2748AD25-9C63-4E12-877B-4DCE96FBED54}</Project> |
<ProjectReference Include="..\..\..\..\Main\Base\Project\ICSharpCode.SharpDevelop.csproj"> |
||||||
<Name>ICSharpCode.SharpDevelop</Name> |
<Project>{2748AD25-9C63-4E12-877B-4DCE96FBED54}</Project> |
||||||
<Private>False</Private> |
<Name>ICSharpCode.SharpDevelop</Name> |
||||||
</ProjectReference> |
<Private>False</Private> |
||||||
<ProjectReference Include="..\..\..\..\Main\Core\Project\ICSharpCode.Core.csproj"> |
</ProjectReference> |
||||||
<Project>{35CEF10F-2D4C-45F2-9DD1-161E0FEC583C}</Project> |
<ProjectReference Include="..\..\..\..\Main\Core\Project\ICSharpCode.Core.csproj"> |
||||||
<Name>ICSharpCode.Core</Name> |
<Project>{35CEF10F-2D4C-45F2-9DD1-161E0FEC583C}</Project> |
||||||
<Private>False</Private> |
<Name>ICSharpCode.Core</Name> |
||||||
</ProjectReference> |
<Private>False</Private> |
||||||
<ProjectReference Include="..\..\..\..\Main\ICSharpCode.Core.Presentation\ICSharpCode.Core.Presentation.csproj"> |
</ProjectReference> |
||||||
<Project>{7E4A7172-7FF5-48D0-B719-7CD959DD1AC9}</Project> |
<ProjectReference Include="..\..\..\..\Main\ICSharpCode.Core.Presentation\ICSharpCode.Core.Presentation.csproj"> |
||||||
<Name>ICSharpCode.Core.Presentation</Name> |
<Project>{7E4A7172-7FF5-48D0-B719-7CD959DD1AC9}</Project> |
||||||
<Private>False</Private> |
<Name>ICSharpCode.Core.Presentation</Name> |
||||||
</ProjectReference> |
<Private>False</Private> |
||||||
<ProjectReference Include="..\..\..\..\Main\ICSharpCode.Core.WinForms\ICSharpCode.Core.WinForms.csproj"> |
</ProjectReference> |
||||||
<Project>{857CA1A3-FC88-4BE0-AB6A-D1EE772AB288}</Project> |
<ProjectReference Include="..\..\..\..\Main\ICSharpCode.Core.WinForms\ICSharpCode.Core.WinForms.csproj"> |
||||||
<Name>ICSharpCode.Core.WinForms</Name> |
<Project>{857CA1A3-FC88-4BE0-AB6A-D1EE772AB288}</Project> |
||||||
<Private>False</Private> |
<Name>ICSharpCode.Core.WinForms</Name> |
||||||
</ProjectReference> |
<Private>False</Private> |
||||||
<ProjectReference Include="..\..\..\..\Main\ICSharpCode.SharpDevelop.Dom\Project\ICSharpCode.SharpDevelop.Dom.csproj"> |
</ProjectReference> |
||||||
<Project>{924EE450-603D-49C1-A8E5-4AFAA31CE6F3}</Project> |
<ProjectReference Include="..\..\..\..\Main\ICSharpCode.SharpDevelop.Dom\Project\ICSharpCode.SharpDevelop.Dom.csproj"> |
||||||
<Name>ICSharpCode.SharpDevelop.Dom</Name> |
<Project>{924EE450-603D-49C1-A8E5-4AFAA31CE6F3}</Project> |
||||||
<Private>False</Private> |
<Name>ICSharpCode.SharpDevelop.Dom</Name> |
||||||
</ProjectReference> |
<Private>False</Private> |
||||||
<ProjectReference Include="..\..\..\..\Main\ICSharpCode.SharpDevelop.Widgets\Project\ICSharpCode.SharpDevelop.Widgets.csproj"> |
</ProjectReference> |
||||||
<Project>{8035765F-D51F-4A0C-A746-2FD100E19419}</Project> |
<ProjectReference Include="..\..\..\..\Main\ICSharpCode.SharpDevelop.Widgets\Project\ICSharpCode.SharpDevelop.Widgets.csproj"> |
||||||
<Name>ICSharpCode.SharpDevelop.Widgets</Name> |
<Project>{8035765F-D51F-4A0C-A746-2FD100E19419}</Project> |
||||||
<Private>False</Private> |
<Name>ICSharpCode.SharpDevelop.Widgets</Name> |
||||||
</ProjectReference> |
<Private>False</Private> |
||||||
<ProjectReference Include="..\..\FormsDesigner\Project\FormsDesigner.csproj"> |
</ProjectReference> |
||||||
<Project>{7D7E92DF-ACEB-4B69-92C8-8AC7A703CD57}</Project> |
<ProjectReference Include="..\..\FormsDesigner\Project\FormsDesigner.csproj"> |
||||||
<Name>FormsDesigner</Name> |
<Project>{7D7E92DF-ACEB-4B69-92C8-8AC7A703CD57}</Project> |
||||||
<Private>False</Private> |
<Name>FormsDesigner</Name> |
||||||
</ProjectReference> |
<Private>False</Private> |
||||||
<ProjectReference Include="..\WpfDesign.Designer\Project\WpfDesign.Designer.csproj"> |
</ProjectReference> |
||||||
<Project>{78CC29AC-CC79-4355-B1F2-97936DF198AC}</Project> |
<ProjectReference Include="..\WpfDesign.Designer\Project\WpfDesign.Designer.csproj"> |
||||||
<Name>WpfDesign.Designer</Name> |
<Project>{78CC29AC-CC79-4355-B1F2-97936DF198AC}</Project> |
||||||
<Private>False</Private> |
<Name>WpfDesign.Designer</Name> |
||||||
</ProjectReference> |
<Private>False</Private> |
||||||
<ProjectReference Include="..\WpfDesign.XamlDom\Project\WpfDesign.XamlDom.csproj"> |
</ProjectReference> |
||||||
<Project>{88DA149F-21B2-48AB-82C4-28FB6BDFD783}</Project> |
<ProjectReference Include="..\WpfDesign.XamlDom\Project\WpfDesign.XamlDom.csproj"> |
||||||
<Name>WpfDesign.XamlDom</Name> |
<Project>{88DA149F-21B2-48AB-82C4-28FB6BDFD783}</Project> |
||||||
<Private>False</Private> |
<Name>WpfDesign.XamlDom</Name> |
||||||
</ProjectReference> |
<Private>False</Private> |
||||||
<ProjectReference Include="..\WpfDesign\Project\WpfDesign.csproj"> |
</ProjectReference> |
||||||
<Project>{66A378A1-E9F4-4AD5-8946-D0EC06C2902F}</Project> |
<ProjectReference Include="..\WpfDesign\Project\WpfDesign.csproj"> |
||||||
<Name>WpfDesign</Name> |
<Project>{66A378A1-E9F4-4AD5-8946-D0EC06C2902F}</Project> |
||||||
<Private>False</Private> |
<Name>WpfDesign</Name> |
||||||
</ProjectReference> |
<Private>False</Private> |
||||||
<Page Include="Src\ImageSourceEditor\ChooseImageDialog.xaml" /> |
</ProjectReference> |
||||||
<Page Include="Src\ImageSourceEditor\ImageSourceEditor.xaml" /> |
<Page Include="Src\ImageSourceEditor\ChooseImageDialog.xaml" /> |
||||||
<Page Include="Src\ObjectEditor.xaml" /> |
<Page Include="Src\ImageSourceEditor\ImageSourceEditor.xaml" /> |
||||||
</ItemGroup> |
<Page Include="Src\ObjectEditor.xaml" /> |
||||||
<ItemGroup> |
</ItemGroup> |
||||||
<Folder Include="Images" /> |
<ItemGroup /> |
||||||
<Folder Include="Src\ImageSourceEditor" /> |
|
||||||
<Folder Include="Src\Commands" /> |
|
||||||
</ItemGroup> |
|
||||||
</Project> |
</Project> |
||||||
Loading…
Reference in new issue