Exemple #1
0
 public FormerlySerializedAsRefactoringPage(Lifetime lifetime, SerializedFieldRenameModel model)
     : base(lifetime)
 {
     myModel = model;
     myShouldAddFormerlySerializedAs = new Property <bool>(lifetime, "ShouldAddAttribute", myModel.ShouldAddFormerlySerializedAs);
     myContent = myShouldAddFormerlySerializedAs.GetBeCheckBox(lifetime, "Add _FormerlySerializedAs attribute").InAutoGrid();
 }
        public FormerlySerializedAsAtomicRename(IDeclaredElement declaredElement, string newName, ISettingsStore settingsStore)
        {
            myModel = new SerializedFieldRenameModel(settingsStore);

            myPointer = declaredElement.CreateElementPointer();
            OldName   = declaredElement.ShortName;
            NewName   = newName;
        }
Exemple #3
0
        public FormerlySerializedAsRefactoringPage(Lifetime lifetime, SerializedFieldRenameModel model)
            : base(lifetime)
        {
            myModel   = model;
            myContent = new BeGrid(GridOrientation.Vertical);
            myShouldAddFormerlySerializedAs = new Property <bool>(lifetime, "ShouldAddAttribute", myModel.ShouldAddFormerlySerializedAs);
            var checkBox = myShouldAddFormerlySerializedAs.GetBeCheckBox(lifetime, "Add _FormerlySerializedAs attribute");

            myContent.AddElement(checkBox);
        }
        public FormerlySerializedAsAtomicRename(IDeclaredElement declaredElement, string newName,
                                                ISettingsStore settingsStore, KnownTypesCache knownTypesCache, bool isRenameShouldBeSilent)
        {
            myKnownTypesCache        = knownTypesCache;
            myIsRenameShouldBeSilent = isRenameShouldBeSilent;
            myModel = new SerializedFieldRenameModel(settingsStore);

            myPointer = declaredElement.CreateElementPointer();
            OldName   = declaredElement.ShortName;
            NewName   = newName;
        }