Ignore:
Timestamp:
Aug 24, 2010, 9:40:17 PM (11 years ago)
Author:
malischewski
Message:

Added combo box in the settings panel for switching between entropy functions (default is the NativeCryptography one)
Both functions produces identical results, NativeCryptography supposedly faster (not yet tested).

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/CrypPlugins/CostFunction/CostFunctionSettings.cs

    r1858 r1868  
    110110            }
    111111        }
     112        public int entropyselect;
     113        [TaskPane("Select Entropy function", "Select an Entropy function", null, 9, false, DisplayLevel.Expert, ControlType.ComboBox, new string[] { "External (NativeCryptography, default)", "Internal" })]
     114        public int entropy
     115        {
     116            get
     117            {
     118                return entropyselect;
     119            }
     120
     121            set
     122            {
     123                entropyselect = value;
     124                OnPropertyChanged("entropy");
     125            }
     126        }
     127
    112128        public string customfwtpath;
    113129        public int fwt = 0; //fwt = fitness weight table
     
    184200
    185201            }
    186            
    187 
     202            if (functionType.Equals(1))
     203            {
     204                TaskPaneAttributeChanged(this, new TaskPaneAttributeChangedEventArgs(new TaskPaneAttribteContainer("entropyselect", Visibility.Visible)));
     205            }
     206            else
     207            {
     208                TaskPaneAttributeChanged(this, new TaskPaneAttributeChangedEventArgs(new TaskPaneAttribteContainer("entropyselect", Visibility.Collapsed)));
     209            }
    188210        }
    189211
Note: See TracChangeset for help on using the changeset viewer.