private UserFriendlySupplier CloneFor(IPreferenceFolder snapshot) { UserFriendlySupplier n = new UserFriendlySupplier(); n._folder = snapshot; n._i = snapshot.ChildAt(0) as IIntPreferenceItem; n._s = snapshot.ChildAt(1) as IStringPreferenceItem; return(n); }
private KeyBindConfiguration GetKeyBindInternal(IPreferenceFolder folder) { Debug.Assert(folder.Id == PLUGIN_ID); IPreferenceLooseNode ln = (IPreferenceLooseNode)folder.ChildAt(_keyBindNode.Index); Debug.Assert(ln != null); KeyBindConfiguration kb = ln.Content as KeyBindConfiguration; Debug.Assert(kb != null); return(kb); }
public IPreferenceItem ConvertItem(IPreferenceFolder child_folder, IPreferenceItem item_in_template) { if (_id != child_folder.Id) { throw new ArgumentException("child_folder is not compatible for this array"); } if (!_template.Contains(item_in_template)) { throw new ArgumentException("item_in_template must be a member of the template folder"); } IPreferenceItem r = (IPreferenceItem)child_folder.ChildAt(item_in_template.Index); Debug.Assert(r.GetType() == item_in_template.GetType()); return(r); }
private UserFriendlySupplier CloneFor(IPreferenceFolder snapshot) { UserFriendlySupplier n = new UserFriendlySupplier(); n._folder = snapshot; n._i = snapshot.ChildAt(0) as IIntPreferenceItem; n._s = snapshot.ChildAt(1) as IStringPreferenceItem; return n; }
protected IIntPreferenceItem ConvertItem(IIntPreferenceItem item) { return(_folder.ChildAt(item.Index).AsItem().AsInt()); }
private KeyBindConfiguration GetKeyBindInternal(IPreferenceFolder folder) { Debug.Assert(folder.Id == PLUGIN_ID); IPreferenceLooseNode ln = (IPreferenceLooseNode)folder.ChildAt(_keyBindNode.Index); Debug.Assert(ln != null); KeyBindConfiguration kb = ln.Content as KeyBindConfiguration; Debug.Assert(kb != null); return kb; }