Changeset 2581


Ignore:
Timestamp:
Feb 5, 2011, 1:30:58 AM (10 years ago)
Author:
matkovic
Message:

-WorkspaceManager: Background changed from GradientBrush to SolidColorBrush
-PluginContainerView: TextBox caret loses 'focus' after key "enter" is down/up.

Location:
trunk/CrypPlugins/WorkspaceManager
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • trunk/CrypPlugins/WorkspaceManager/View/Container/PluginContainerView.xaml

    r2280 r2581  
    332332            </Grid>
    333333        </DockPanel>
    334         <TextBox x:Name="CTextBox" DockPanel.Dock="Bottom" Foreground="Black" FontSize="12" Opacity="0.5" HorizontalAlignment="Left" TextChanged="CTextBox_TextChanged" Style="{StaticResource ResourceKey=BasicTextBoxStyle}" Width="120" Height="18" Margin="0,-10,0,0" FontFamily="Palatino"></TextBox>
     334        <TextBox x:Name="CTextBox" DockPanel.Dock="Bottom" Foreground="Black" FontSize="12" Opacity="0.5" KeyUp="TextBox_KeyUp" HorizontalAlignment="Left" TextChanged="CTextBox_TextChanged" PreviewMouseLeftButtonDown="TextBox_MouseLeftButtonDown" Style="{StaticResource ResourceKey=BasicTextBoxStyle}" Width="120" Height="18" Margin="0,-10,0,0" FontFamily="Palatino"></TextBox>
    335335       
    336336       
  • trunk/CrypPlugins/WorkspaceManager/View/Container/PluginContainerView.xaml.cs

    r2385 r2581  
    941941                ICPanelVisibility = Visibility.Visible;
    942942        }
     943
     944        protected override void OnInitialized(EventArgs e)
     945        {
     946            EventManager.RegisterClassHandler(typeof(TextBox),
     947                TextBox.KeyUpEvent,
     948                new System.Windows.Input.KeyEventHandler(TextBox_KeyUp));
     949            base.OnInitialized(e);
     950        }
     951
     952        private void TextBox_KeyUp(object sender, System.Windows.Input.KeyEventArgs e)
     953        {
     954            if (e.Key != System.Windows.Input.Key.Enter) return;
     955            ((TextBox)sender).CaretBrush = Brushes.Transparent;
     956            e.Handled = true;
     957        }
     958
     959        private void TextBox_MouseLeftButtonDown(object sender, MouseButtonEventArgs e)
     960        {
     961            ((TextBox)sender).CaretBrush = Brushes.Gray;
     962        }
     963
    943964    }
    944965
  • trunk/CrypPlugins/WorkspaceManager/View/Resource/Brushes.xaml

    r2280 r2581  
    182182
    183183
    184     <RadialGradientBrush x:Key="NormalBrush" RadiusX="1.1" RadiusY="2.8" Center="0.524,1.2" GradientOrigin="0.524,1.2">
     184    <SolidColorBrush x:Key="NormalBrush" Color="#add3f5"></SolidColorBrush>
     185   
     186    <!--<RadialGradientBrush x:Key="NormalBrush" RadiusX="1.1" RadiusY="2.8" Center="0.524,1.2" GradientOrigin="0.524,1.2">
    185187        <GradientStop Color="#add3f5" Offset="0.0" />
    186188        <GradientStop Color="#293955" Offset="1" />
    187     </RadialGradientBrush>
     189    </RadialGradientBrush>-->
    188190
    189191    <LinearGradientBrush x:Key="NormalBrush2" StartPoint="0,0" EndPoint="0,1">
  • trunk/CrypPlugins/WorkspaceManager/WorkspaceManager.csproj

    r2565 r2581  
    406406  </ItemGroup>
    407407  <ItemGroup>
    408     <Resource Include="View\Image\WorkspaceManager.ico" />
    409   </ItemGroup>
    410   <ItemGroup>
    411     <Resource Include="View\Image\WorkspaceManagerIcon.png" />
     408    <Resource Include="View\Image\WorkspaceManagerIcon.ico" />
    412409  </ItemGroup>
    413410  <Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
Note: See TracChangeset for help on using the changeset viewer.