Skip to content

Commit

Permalink
Override BreakingLinks dialog control.
Browse files Browse the repository at this point in the history
  • Loading branch information
MariiaHubenko committed May 16, 2018
1 parent 8ff42a5 commit a5e7fc7
Show file tree
Hide file tree
Showing 2 changed files with 79 additions and 1 deletion.
6 changes: 5 additions & 1 deletion src/Sitecore.Support.221558/Sitecore.Support.221558.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -58,12 +58,16 @@
</ItemGroup>
<ItemGroup>
<Compile Include="Properties\AssemblyInfo.cs" />
<Compile Include="Shell\Applications\Dialogs\BreakingLinks\BreakingLinksForm.cs" />
<Compile Include="shell\Applications\Dialogs\BreakingLinks\BreakingLinksForm.cs" />
</ItemGroup>
<ItemGroup>
<None Include="packages.config" />
<None Include="web.config" />
</ItemGroup>
<ItemGroup />
<ItemGroup>
<Content Include="shell\Override\BreakingLinks.xml" />
</ItemGroup>
<PropertyGroup>
<VisualStudioVersion Condition="'$(VisualStudioVersion)' == ''">10.0</VisualStudioVersion>
<VSToolsPath Condition="'$(VSToolsPath)' == ''">$(MSBuildExtensionsPath32)\Microsoft\VisualStudio\v$(VisualStudioVersion)</VSToolsPath>
Expand Down
74 changes: 74 additions & 0 deletions src/Sitecore.Support.221558/shell/Override/BreakingLinks.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,74 @@
<?xml version="1.0" encoding="utf-8" ?>
<control xmlns:def="Definition" xmlns="http://schemas.sitecore.net/Visual-Studio-Intellisense">
<BreakingLinks>
<FormDialog Icon="Network/32x32/link_delete.png" Header="Breaking Links"
Text="Other items contain links to this item or its subitems. These links should be updated to prevent broken links." OKButton="Continue">
<Stylesheet Src="/sitecore/shell/Applications/Links/BreakingLinks/BreakingLinks.css" />

<CodeBeside Type="Sitecore.Support.Shell.Applications.Dialogs.BreakingLinks.BreakingLinksForm, Sitecore.Support.221558"/>

<Border ID="SelectActionPage">
<Groupbox Header="Items to delete" Padding="2px">
<Border ID="DeletingItems">
</Border>
</Groupbox>

<Border Margin="8px 0px 0px 0px">
<Groupbox Header="Action" Padding="2px">
<Border>
<Radiobutton ID="RemoveButton" Name="Action" Value="Remove" Header="Remove links"/>
</Border>
<Border>
<Radiobutton ID="RelinkButton" Name="Action" Value="Relink" Header="Link to another item" />
</Border>
<Border>
<Radiobutton ID="BreakButton" Name="Action" Value="Break" Header="Leave links – the links will appear in the Broken Links report" Checked="true" />
</Border>
</Groupbox>
</Border>

<Border Margin="8px 0px 0px 0px">
<Button Header="Edit Links" Click="EditLinks"/>
</Border>
</Border>

<Border ID="SelectItemPage" Height="100%" Visible="false" >
<DataContext ID="DataContext" Root="/" Folder="/sitecore/content" DataViewName="Master"/>

<GridPanel Width="100%" Height="100%">

<Literal Text="Select another item."/>

<Scrollbox Width="100%" Height="100%" GridPanel.Height="100%" Padding="0px">
<TreeviewEx ID="Link" DataContext="DataContext" />
</Scrollbox>

</GridPanel>
</Border>

<Border ID="ExecutingPage" Visible="false">
<Border class="scWizardProgressPage">
<ThemedImage class="scSpinner" Src="Images/ProgressIndicator/sc-spinner32.gif" />
<Literal class="scFieldLabel scActionText" Text="Updating Links..."/>
<Border ID="Status" Align="center" GridPanel.Align="center">&#160;</Border>
</Border>
</Border>

<Border ID="FailedPage" class="scStretch" Visible="false">
<Memo ID="ErrorText" ReadOnly="true" class="scStretch"/>
</Border>

<Border ID="LinksBrokenOrRemovedPage" Margin="0px" Visible="false">
<GridPanel Width="100%" Height="100%">
<Border class="scWarning">
<ThemedImage Src="/sitecore/shell/themes/standard/Images/warning_yellow.png" />
<Literal ID="LinksBrokenOrRemovedCount" Text=""/>
</Border>
</GridPanel>
</Border>

<Button ID="BackButton" def:placeholder="Buttons" style="float:right; margin-right: 10px;" Class="scButton" Visible="false" Click="#" Header="Back"/>

</FormDialog>
</BreakingLinks>
</control>

0 comments on commit a5e7fc7

Please sign in to comment.