Changeset 2255


Ignore:
Timestamp:
Dec 23, 2010, 2:44:24 PM (11 years ago)
Author:
Matthäus Wander
Message:

TextInput:

  • added setting to convert input text from Hex or Base64 string to binary data
  • This change might break some samples. Please test and report any failures.

CrypPluginBase:

  • marked further occurences of DisplayLevel as obsolete, see #122
Location:
trunk
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • trunk/CrypPluginBase/Attributes/ContextMenuAttribute.cs

    r947 r2255  
    3636        /// <param name="toolTip">The tool tip is used for all entries.</param>
    3737        /// <param name="order">The order.</param>
    38         /// <param name="displayLevel">The display level.</param>
    3938        /// <param name="controlType">Type of the control.</param>
    4039        /// <param name="arrImagesForControlValues">Image indexes for the control values. Can be null if no images should be used.</param>
    4140        /// <param name="controlValues">Strings for the context menu entries.</param>
    42         public ContextMenuAttribute(string caption, string toolTip, int order, DisplayLevel displayLevel, ContextMenuControlType controlType, int[] arrImagesForControlValues, params string[] controlValues)
     41        public ContextMenuAttribute(string caption, string toolTip, int order, ContextMenuControlType controlType, int[] arrImagesForControlValues, params string[] controlValues)
    4342        {
    4443            this.Caption = caption;
    4544            this.ToolTip = toolTip;
    4645            this.Order = order;           
    47             this.DisplayLevel = displayLevel;
     46//            this.DisplayLevel = displayLevel;
    4847            this.ControlType = controlType;
    4948            this.ControlValues = controlValues;
    5049            this.ArrImagesForControlValues = arrImagesForControlValues;
    5150        }
     51
     52        [Obsolete("DisplayLevel is no longer used, see #122")]
     53        public ContextMenuAttribute(string caption, string toolTip, int order, DisplayLevel displayLevel, ContextMenuControlType controlType, int[] arrImagesForControlValues, params string[] controlValues)
     54            : this(caption, toolTip, order, controlType, arrImagesForControlValues, controlValues)
     55        {
     56        }
    5257    }
    5358}
  • trunk/CrypPlugins/TextInput/TextInput.cs

    r1265 r2255  
    8888    }
    8989
     90    private string GetInputString()
     91    {
     92        return (string)this.textInputPresentation.textBoxInputText.Dispatcher.Invoke(DispatcherPriority.Normal, (DispatcherOperationCallback)delegate
     93        {
     94            return textInputPresentation.textBoxInputText.Text;
     95        }, textInputPresentation);
     96    }
     97
     98      private byte[] ConvertHexStringToByteArray(string input)
     99      {
     100          if (String.IsNullOrEmpty(input))
     101              return new byte[0];
     102
     103          StringBuilder cleanHexString = new StringBuilder();
     104
     105          //cleanup the input
     106          foreach (char c in input)
     107          {
     108              if (Uri.IsHexDigit(c))
     109                  cleanHexString.Append(c);
     110          }
     111
     112          int numberChars = cleanHexString.Length;
     113
     114          if (numberChars < 2) // Need at least 2 chars to make one byte
     115              return new byte[0];
     116
     117          byte[] bytes = new byte[numberChars / 2];
     118
     119          for (int i = 0; i < numberChars-1; i += 2)
     120          {
     121              bytes[i / 2] = Convert.ToByte(cleanHexString.ToString().Substring(i, 2), 16);
     122          }
     123          return bytes;
     124      }
     125
     126      private string ConvertBytesToString(byte[] data)
     127      {
     128          switch (settings.Encoding)
     129          {
     130              case TextInputSettings.EncodingTypes.Unicode:
     131                  return Encoding.Unicode.GetString(data);
     132                  break;
     133              case TextInputSettings.EncodingTypes.UTF7:
     134                  return Encoding.UTF7.GetString(data);
     135                  break;
     136              case TextInputSettings.EncodingTypes.UTF8:
     137                  return Encoding.UTF8.GetString(data);
     138                  break;
     139              case TextInputSettings.EncodingTypes.UTF32:
     140                  return Encoding.UTF32.GetString(data);
     141                  break;
     142              case TextInputSettings.EncodingTypes.ASCII:
     143                  return Encoding.ASCII.GetString(data);
     144                  break;
     145              case TextInputSettings.EncodingTypes.BigEndianUnicode:
     146                  return Encoding.BigEndianUnicode.GetString(data);
     147                  break;
     148              default:
     149                  return Encoding.Default.GetString(data);
     150          }
     151      }
     152
     153      private byte[] ConvertStringToByteArray(string inputString)
     154      {
     155          if (String.IsNullOrEmpty(inputString))
     156          {
     157              return new byte[0];
     158          }
     159
     160          // here conversion happens       
     161          switch (settings.Encoding)
     162          {
     163              case TextInputSettings.EncodingTypes.Default:
     164                  return Encoding.Default.GetBytes(inputString);
     165              case TextInputSettings.EncodingTypes.Unicode:
     166                  return Encoding.Unicode.GetBytes(inputString);
     167              case TextInputSettings.EncodingTypes.UTF7:
     168                  return Encoding.UTF7.GetBytes(inputString);
     169              case TextInputSettings.EncodingTypes.UTF8:
     170                  return Encoding.UTF8.GetBytes(inputString);
     171              case TextInputSettings.EncodingTypes.UTF32:
     172                  return Encoding.UTF32.GetBytes(inputString);
     173              case TextInputSettings.EncodingTypes.ASCII:
     174                  return Encoding.ASCII.GetBytes(inputString);
     175              case TextInputSettings.EncodingTypes.BigEndianUnicode:
     176                  return Encoding.BigEndianUnicode.GetBytes(inputString);
     177              default:
     178                  return Encoding.Default.GetBytes(inputString);
     179          }
     180      }
     181
     182      private bool[] ConvertByteArrayToBoolArray(byte[] input)
     183      {
     184          bool[] output = new bool[input.Length];
     185
     186          for (int i = 0; i < output.Length; i++)
     187          {
     188              output[i] = input[i] != 0x00;
     189          }
     190
     191          return output;
     192      }
     193
    90194    # region Properties
    91195
    92     [PropertyInfo(Direction.OutputData, "Text", "Simple text to use as input for other plug-ins.", "", true, false, DisplayLevel.Beginner, QuickWatchFormat.None, null)]
     196    [PropertyInfo(Direction.OutputData, "Text", "Simple text to use as input for other plug-ins.", "", true, false, QuickWatchFormat.None, null)]
    93197    public string TextOutput
    94198    {
    95       //[MethodImpl(MethodImplOptions.Synchronized)]
    96199      get
    97       {       
    98         // GuiLogMessage("Got request for text...", NotificationLevel.Debug);
    99         string ret = (string)this.textInputPresentation.textBoxInputText.Dispatcher.Invoke(DispatcherPriority.Normal, (DispatcherOperationCallback)delegate
    100         {         
    101           return textInputPresentation.textBoxInputText.Text;
    102         }, textInputPresentation);
    103        
    104         if (ret == null || ret == string.Empty)
    105         {
    106           GuiLogMessage("Text: No text provided. Returning null", NotificationLevel.Debug);
    107           return null;
    108         }
    109         return ret;
     200      {
     201          string inputString = GetInputString();
     202
     203          switch(settings.InputFormatSetting)
     204          {
     205              case TextInputSettings.InputFormat.Hex:
     206                  {
     207                      byte[] data = ConvertHexStringToByteArray(inputString);
     208                      return ConvertBytesToString(data);
     209                  }
     210              case TextInputSettings.InputFormat.Base64:
     211                  {
     212                      try
     213                      {
     214                          byte[] data = Convert.FromBase64String(inputString);
     215                          return ConvertBytesToString(data);
     216                      }
     217                      catch (FormatException e)
     218                      {
     219                          GuiLogMessage("Invalid Base64 format", NotificationLevel.Warning);
     220                          return string.Empty;
     221                      }
     222                  }
     223              default: // includes InputFormat.Text
     224                  return inputString;
     225          }
     226         
    110227      }
    111228      set { }
    112229    }
    113230
    114     [PropertyInfo(Direction.OutputData, "Stream", "The text input converted to memory stream.", "", true, false, DisplayLevel.Beginner, QuickWatchFormat.None, null)]
     231    [PropertyInfo(Direction.OutputData, "Stream", "The text input converted to memory stream.", "", true, false, QuickWatchFormat.None, null)]
    115232    public CryptoolStream StreamOutput
    116233    {
    117       //[MethodImpl(MethodImplOptions.Synchronized)]
    118234      get
    119235      {
    120         byte[] arr = GetByteArray(false);
     236        byte[] arr = ByteArrayOutput;
    121237        if (arr != null)
    122238        {
     
    136252    }
    137253
    138     private byte[] byteArrayOutput;
    139     [PropertyInfo(Direction.OutputData, "ByteArray", "The hex values as byte array.", "", true, false, DisplayLevel.Beginner, QuickWatchFormat.None, null)]
     254    [PropertyInfo(Direction.OutputData, "ByteArray", "The hex values as byte array.", "", true, false, QuickWatchFormat.None, null)]
    140255    public byte[] ByteArrayOutput
    141256    {
    142       //[MethodImpl(MethodImplOptions.Synchronized)]
    143257      get
    144258      {
    145         // GuiLogMessage("Got request for ByteArray...", NotificationLevel.Debug);
    146         byteArrayOutput = GetByteArray(true);
    147         if (byteArrayOutput == null)
    148         {
    149           GuiLogMessage("ByteArray: No input provided. Returning null", NotificationLevel.Debug);
    150           return null;
    151         }
    152         return byteArrayOutput;
     259          string inputString = GetInputString();
     260
     261          switch (settings.InputFormatSetting)
     262          {
     263              case TextInputSettings.InputFormat.Hex:
     264                  return ConvertHexStringToByteArray(inputString);
     265              case TextInputSettings.InputFormat.Base64:
     266                  try
     267                  {
     268                      return Convert.FromBase64String(inputString);
     269                  } catch(FormatException e)
     270                  {
     271                      GuiLogMessage("Invalid Base64 format", NotificationLevel.Warning);
     272                      return new byte[0];
     273                  }
     274              default: // includes InputFormat.Text
     275                  return ConvertStringToByteArray(inputString);
     276          }
    153277      }
    154278      set { } // readonly
    155279    }
    156280
    157     public byte[] GetByteArray(bool showMessage)
    158     {
    159         string data = (string)this.textInputPresentation.Dispatcher.Invoke(DispatcherPriority.Normal, (DispatcherOperationCallback)delegate
    160         {
    161             return textInputPresentation.textBoxInputText.Text;
    162         }, null);
    163 
    164         if ((data != null) && (data.Length != 0))
    165         {
    166             // here conversion happens       
    167             switch (settings.Encoding)
    168             {
    169                 case TextInputSettings.EncodingTypes.Default:
    170                     byteArrayOutput = Encoding.Default.GetBytes(data.ToCharArray());
    171                     break;
    172                 case TextInputSettings.EncodingTypes.Unicode:
    173                     byteArrayOutput = Encoding.Unicode.GetBytes(data.ToCharArray());
    174                     break;
    175                 case TextInputSettings.EncodingTypes.UTF7:
    176                     byteArrayOutput = Encoding.UTF7.GetBytes(data.ToCharArray());
    177                     break;
    178                 case TextInputSettings.EncodingTypes.UTF8:
    179                     byteArrayOutput = Encoding.UTF8.GetBytes(data.ToCharArray());
    180                     break;
    181                 case TextInputSettings.EncodingTypes.UTF32:
    182                     byteArrayOutput = Encoding.UTF32.GetBytes(data.ToCharArray());
    183                     break;
    184                 case TextInputSettings.EncodingTypes.ASCII:
    185                     byteArrayOutput = Encoding.ASCII.GetBytes(data.ToCharArray());
    186                     break;
    187                 case TextInputSettings.EncodingTypes.BigEndianUnicode:
    188                     byteArrayOutput = Encoding.BigEndianUnicode.GetBytes(data.ToCharArray());
    189                     break;
    190                 default:
    191                     byteArrayOutput = Encoding.Default.GetBytes(data.ToCharArray());
    192                     break;
    193             }
    194             return byteArrayOutput;
    195         }
    196 
    197         return null;
    198     }
    199 
    200     private bool[] boolArrayOutput;
    201     [PropertyInfo(Direction.OutputData, "BoolArray", "The text input converted to bool array ('0' char equals false, else true).", "", true, false, DisplayLevel.Beginner, QuickWatchFormat.None, null)]
     281    [PropertyInfo(Direction.OutputData, "BoolArray", "The text input converted to bool array ('0' char or 0x00 equals false, else true).", "", true, false, QuickWatchFormat.None, null)]
    202282    public bool[] BoolArrayOutput
    203283    {
    204         //[MethodImpl(MethodImplOptions.Synchronized)]
    205284        get
    206285        {
    207             // GuiLogMessage("Got request for BoolArray...", NotificationLevel.Debug);
    208             boolArrayOutput = GetBoolArray(true);
    209             if (boolArrayOutput == null)
     286            string inputString = GetInputString();
     287
     288            switch(settings.InputFormatSetting)
    210289            {
    211                 GuiLogMessage("BoolArray: No input provided. Returning null", NotificationLevel.Debug);
    212                 return null;
     290                case TextInputSettings.InputFormat.Hex:
     291                    {
     292                        byte[] data = ConvertHexStringToByteArray(inputString);
     293                        return ConvertByteArrayToBoolArray(data);
     294                    }
     295                case TextInputSettings.InputFormat.Base64:
     296                    {
     297                        try
     298                        {
     299                            byte[] data = Convert.FromBase64String(inputString);
     300                            return ConvertByteArrayToBoolArray(data);
     301                        }
     302                        catch (FormatException e)
     303                        {
     304                            GuiLogMessage("Invalid Base64 format", NotificationLevel.Warning);
     305                            return new bool[0];
     306                        }
     307                    }
     308                default: // includes InputFormat.Text
     309                    bool[] output = new bool[inputString.Length];
     310                    for(int i = 0; i < output.Length; i++)
     311                    {
     312                        output[i] = inputString[i] != '0';
     313                    }
     314                    return output;
    213315            }
    214             return boolArrayOutput;
    215316        }
    216317        set { } // readonly
    217318    }
    218319
    219     public bool[] GetBoolArray(bool showMessage)
    220     {
    221         string data = (string)this.textInputPresentation.Dispatcher.Invoke(DispatcherPriority.Normal, (DispatcherOperationCallback)delegate
    222         {
    223             return textInputPresentation.textBoxInputText.Text;
    224         }, null);
    225 
    226         if ((data != null) && (data.Length != 0))
    227         {
    228             // convert data into char array
    229             char[] dataCharArray = data.ToCharArray();
    230 
    231             boolArrayOutput = new bool[data.Length];
    232 
    233             for (int i = 0; i < data.Length; i++)
    234             {
    235                boolArrayOutput[i] = (Convert.ToInt64(dataCharArray[i]) == 48) ? false : true;
    236                //if (Convert.ToInt64(dataCharArray[i]) == 48) boolArrayOutput[i] = false; else boolArrayOutput[i] = true;
    237             }
    238 
    239             return boolArrayOutput;
    240         }
    241 
    242         return null;
    243     }
    244 
    245320    #endregion
    246321
     
    274349      }
    275350      listCryptoolStreams.Clear();
    276 
    277       byteArrayOutput = null;
    278351
    279352      textInputPresentation.textBoxInputText.TextChanged -= textBoxInputText_TextChanged;
     
    299372    public void PreExecution()
    300373    {
    301       byteArrayOutput = null;
    302374      // textInputPresentation.labelBytesCount.Content = "0 Bytes";
    303375    }
  • trunk/CrypPlugins/TextInput/TextInputSettings.cs

    r1259 r2255  
    2828    #region Private variables
    2929    private EncodingTypes encoding = EncodingTypes.Default;
     30    private InputFormat inputFormat = InputFormat.Text;
    3031    private bool hasChanges = false;
    3132    #endregion
    3233
    3334    public enum EncodingTypes { Default = 0, Unicode = 1, UTF7 = 2, UTF8 = 3, UTF32 = 4, ASCII = 5, BigEndianUnicode = 6 };
     35    public enum InputFormat { Text, Hex, Base64 }
    3436   
    3537    public delegate void TextInputLogMessage(string message, NotificationLevel loglevel);
     
    7274    /// Encoding property used in the Settings pane.
    7375    /// </summary>
    74     [ContextMenu("Stream encoding", "Choose the expected encoding of the byte array and stream.", 1, DisplayLevel.Experienced, ContextMenuControlType.ComboBox, null, new string[] { "Default system encoding", "Unicode", "UTF-7", "UTF-8", "UTF-32", "ASCII", "Big endian unicode" })]
    75     [TaskPane("Stream encoding", "Choose the expected encoding of the byte array and stream.", "", 1, false, DisplayLevel.Experienced, ControlType.RadioButton, new string[] { "Default system encoding", "Unicode", "UTF-7", "UTF-8", "UTF-32", "ASCII", "Big endian unicode" })]
     76    [ContextMenu("Character encoding", "Choose the expected encoding of the byte array and stream.", 1, ContextMenuControlType.ComboBox, null, new string[] { "Default system encoding", "Unicode", "UTF-7", "UTF-8", "UTF-32", "ASCII", "Big endian unicode" })]
     77    [TaskPane("Character encoding", "Choose the expected encoding of the byte array and stream.", "", 1, false, ControlType.RadioButton, new string[] { "Default system encoding", "Unicode", "UTF-7", "UTF-8", "UTF-32", "ASCII", "Big endian unicode" })]
    7678    public int EncodingSetting
    7779    {
     
    9092        }
    9193      }
     94    }
     95
     96    /// <summary>
     97    /// Gets or sets the presentation format setting.
     98    /// </summary>
     99    /// <value>The presentation format setting.</value>
     100    [ContextMenu("Input format", "Choose the input format that will be decoded (if applicable) prior to further processing.", 2, ContextMenuControlType.ComboBox, null, new string[] { "Plain text", "Hex", "Base64" })]
     101    [TaskPane("Input format", "Choose the input format that will be decoded (if applicable) prior to further processing.", null, 2, false, ControlType.RadioButton, new string[] { "Plain text", "Hex", "Base64" })]
     102    public InputFormat InputFormatSetting
     103    {
     104        get
     105        {
     106            return this.inputFormat;
     107        }
     108        set
     109        {
     110            if (this.inputFormat != value) HasChanges = true;
     111            this.inputFormat = value;
     112            OnPropertyChanged("InputFormatSetting");
     113        }
    92114    }
    93115   
  • trunk/CrypPlugins/TextOutput/TextOutputSettings.cs

    r1263 r2255  
    7979    /// Encoding property used in the Settings pane.
    8080    /// </summary>
    81     [ContextMenu("Input encoding", "Choose the expected encoding of the input.", 1, DisplayLevel.Experienced, ContextMenuControlType.ComboBox, null, new string[] { "Default system encoding", "Unicode", "UTF-7", "UTF-8", "UTF-32", "ASCII", "Big endian unicode" })]
    82     [TaskPane("Input encoding", "Choose the expected encoding of the input. (The input will be interpreted as set here, no matter what the bytes really mean)", null, 1, false, DisplayLevel.Experienced, ControlType.RadioButton, new string[] { "Default system encoding", "Unicode", "UTF-7", "UTF-8", "UTF-32", "ASCII", "Big endian unicode" })]
     81    [ContextMenu("Input encoding", "Choose the expected encoding of the input.", 1, ContextMenuControlType.ComboBox, null, new string[] { "Default system encoding", "Unicode", "UTF-7", "UTF-8", "UTF-32", "ASCII", "Big endian unicode" })]
     82    [TaskPane("Input encoding", "Choose the expected encoding of the input. (The input will be interpreted as set here, no matter what the bytes really mean)", null, 1, false, ControlType.RadioButton, new string[] { "Default system encoding", "Unicode", "UTF-7", "UTF-8", "UTF-32", "ASCII", "Big endian unicode" })]
    8383    public int EncodingSetting
    8484    {
     
    100100    /// </summary>
    101101    /// <value>The presentation format setting.</value>
    102     [ContextMenu("Presentation format", "Choose the format that will be used te present the input data.", 2, DisplayLevel.Experienced, ContextMenuControlType.ComboBox, null, new string[] { "Text", "Hex", "Base64", "Decimal" })]
    103     [TaskPane("Presentation format", "Choose the format that will be used te present the input data.", null, 2, false, DisplayLevel.Experienced, ControlType.RadioButton, new string[] { "Text", "Hex", "Base64", "Decimal" })]
     102    [ContextMenu("Presentation format", "Choose the format that will be used to present the input data.", 2, ContextMenuControlType.ComboBox, null, new string[] { "Text", "Hex", "Base64", "Decimal" })]
     103    [TaskPane("Presentation format", "Choose the format that will be used to present the input data.", null, 2, false, ControlType.RadioButton, new string[] { "Text", "Hex", "Base64", "Decimal" })]
    104104    public int PresentationFormatSetting
    105105    {
     
    120120    /// Maximum size property used in the settings pane.
    121121    /// </summary>
    122     [TaskPane("Maximum length", "Provide the maximum number of bytes to convert.", null, 3, false, DisplayLevel.Professional, ControlType.NumericUpDown, ValidationType.RangeInteger, 1, 65536)]
     122    [TaskPane("Maximum length", "Provide the maximum number of bytes to convert.", null, 3, false, ControlType.NumericUpDown, ValidationType.RangeInteger, 1, 65536)]
    123123    public int MaxLength
    124124    {
     
    136136
    137137    private bool append = false;
    138     [ContextMenu("Append text input", "With this checkbox enabled, incoming text will be appended to the current text.", 0, DisplayLevel.Experienced, ContextMenuControlType.CheckBox, null, new string[] { "Append text input" })]
    139     [TaskPane("Append text input", "With this checkbox enabled, incoming text will be appended to the current text.", "Append", 0, false, DisplayLevel.Beginner, ControlType.CheckBox, "", null)]
     138    [ContextMenu("Append text input", "With this checkbox enabled, incoming text will be appended to the current text.", 0, ContextMenuControlType.CheckBox, null, new string[] { "Append text input" })]
     139    [TaskPane("Append text input", "With this checkbox enabled, incoming text will be appended to the current text.", "Append", 0, false, ControlType.CheckBox, "", null)]
    140140    public bool Append
    141141    {
     
    153153
    154154    private int appendBreaks = 1;
    155     [TaskPane("Append n-breaks", "Defines how much new lines are added after new input. (Applies only if \"Append text input\" is active.)", "Append", 0, false, DisplayLevel.Experienced, ControlType.NumericUpDown, ValidationType.RangeInteger, 0, int.MaxValue)]
     155    [TaskPane("Append n-breaks", "Defines how much new lines are added after new input. (Applies only if \"Append text input\" is active.)", "Append", 0, false, ControlType.NumericUpDown, ValidationType.RangeInteger, 0, int.MaxValue)]
    156156    public int AppendBreaks
    157157    {
     
    192192    }
    193193
    194     [TaskPane("Type", "Select DataType of plugin.", "", 4, false, DisplayLevel.Beginner, ControlType.ComboBox, new string[] { "CryptoolStream", "string", "byte[]", "boolean", "int", "double", "object" })]
     194    [TaskPane("Type", "Select DataType of plugin.", "", 4, false, ControlType.ComboBox, new string[] { "CryptoolStream", "string", "byte[]", "boolean", "int", "double", "object" })]
    195195    public int DataType
    196196    {
     
    209209
    210210    private bool booleanAsNumeric = false;
    211     [ContextMenu("Display boolean as numeric value", "With this checkbox enabled, incoming boolean values will be displayed as numeric values (1/0 instead of True/False).", 5, DisplayLevel.Experienced, ContextMenuControlType.CheckBox, null, new string[] { "Display boolean as numeric value" })]
    212     [TaskPane("Display boolean as numeric value", "With this checkbox enabled, incoming boolean values will be displayed as numeric values (1/0 instead of True/False).", null, 5, false, DisplayLevel.Beginner, ControlType.CheckBox, "", null)]
     211    [ContextMenu("Display boolean as numeric value", "With this checkbox enabled, incoming boolean values will be displayed as numeric values (1/0 instead of True/False).", 5, ContextMenuControlType.CheckBox, null, new string[] { "Display boolean as numeric value" })]
     212    [TaskPane("Display boolean as numeric value", "With this checkbox enabled, incoming boolean values will be displayed as numeric values (1/0 instead of True/False).", null, 5, false, ControlType.CheckBox, "", null)]
    213213    public bool BooleanAsNumeric
    214214    {
     
    226226
    227227    private bool flushOnPreExecution = true;
    228     [ContextMenu("Flush text on PreExec", "Flush all text boxes on PreExecution call.", 6, DisplayLevel.Beginner, ContextMenuControlType.CheckBox, null, new string[] {"Flush text on PreExec"})]
    229     [TaskPane("Flush text on PreExec", "Flush all text boxes on PreExecution call.", null, 6, false, DisplayLevel.Beginner, ControlType.CheckBox, null)]
     228    [ContextMenu("Flush text on PreExec", "Flush all text boxes on PreExecution call.", 6, ContextMenuControlType.CheckBox, null, new string[] {"Flush text on PreExec"})]
     229    [TaskPane("Flush text on PreExec", "Flush all text boxes on PreExecution call.", null, 6, false, ControlType.CheckBox, null)]
    230230    public bool FlushOnPreExecution
    231231    {
Note: See TracChangeset for help on using the changeset viewer.