本文整理汇总了C#中System.ComponentModel.Design.ComponentChangedEventArgs类的典型用法代码示例。如果您正苦于以下问题:C# ComponentChangedEventArgs类的具体用法?C# ComponentChangedEventArgs怎么用?C# ComponentChangedEventArgs使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
ComponentChangedEventArgs类属于System.ComponentModel.Design命名空间,在下文中一共展示了ComponentChangedEventArgs类的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的C#代码示例。
示例1: ComponentChangeSvc_ComponentChanged
private void ComponentChangeSvc_ComponentChanged(object sender, ComponentChangedEventArgs e)
{
if (this.containerSelectorGlyph != null)
{
this.containerSelectorGlyph.UpdateGlyph();
}
}
开发者ID:pritesh-mandowara-sp,项目名称:DecompliedDotNetLibraries,代码行数:7,代码来源:ToolStripPanelDesigner.cs
示例2: ComponentChangeSvc_ComponentChanged
private void ComponentChangeSvc_ComponentChanged(object sender, ComponentChangedEventArgs e)
{
BindingNavigator component = (BindingNavigator) base.Component;
if (((e.Component != null) && (e.Component == component.CountItem)) && ((e.Member != null) && (e.Member.Name == "Text")))
{
component.CountItemFormat = component.CountItem.Text;
}
}
开发者ID:pritesh-mandowara-sp,项目名称:DecompliedDotNetLibraries,代码行数:8,代码来源:BindingNavigatorDesigner.cs
示例3: ComponentChanged
private void ComponentChanged(object sender, ComponentChangedEventArgs e)
{
BindingNavigatorEx component = (BindingNavigatorEx)base.Component;
if (((e.Component != null) && (e.Component == component.CountLabel)) && ((e.Member != null) && (e.Member.Name == "Text")))
{
component.CountLabelFormat = component.CountLabel.Text;
}
}
开发者ID:huamanhtuyen,项目名称:VNACCS,代码行数:8,代码来源:BindingNavigatorExDesigner.cs
示例4: OnComponentChanged
private void OnComponentChanged(object sender, ComponentChangedEventArgs e)
{
if (((e.Component == base.Component) && (e.Member != null)) && (e.Member.Name == "Items"))
{
PropertyDescriptor descriptor = TypeDescriptor.GetProperties(base.Component)["Name"];
if (descriptor != null)
{
this.UpdateControlName(descriptor.GetValue(base.Component).ToString());
}
}
}
开发者ID:pritesh-mandowara-sp,项目名称:DecompliedDotNetLibraries,代码行数:11,代码来源:ListBoxDesigner.cs
示例5: OnComponentChanged
private void OnComponentChanged(object sender, ComponentChangedEventArgs e)
{
if (((this.bindingUpdatedByUser && (e.Component == base.Component)) && (e.Member != null)) && ((e.Member.Name == "DataSource") || (e.Member.Name == "DataMember")))
{
this.bindingUpdatedByUser = false;
DataSourceProviderService service = (DataSourceProviderService) this.GetService(typeof(DataSourceProviderService));
if (service != null)
{
service.NotifyDataSourceComponentAdded(base.Component);
}
}
}
开发者ID:pritesh-mandowara-sp,项目名称:DecompliedDotNetLibraries,代码行数:12,代码来源:BindingSourceDesigner.cs
示例6: OnComponentChanged
public override void OnComponentChanged(object sender, ComponentChangedEventArgs ce)
{
base.OnComponentChanged(sender, new ComponentChangedEventArgs(ce.Component, null, null, null));
}
开发者ID:pritesh-mandowara-sp,项目名称:DecompliedDotNetLibraries,代码行数:4,代码来源:LiteralDesigner.cs
示例7: OnComponentChanged
void OnComponentChanged (object sender, ComponentChangedEventArgs e)
{
// BaseImageItem item = e.Component as BaseImageItem;
//
// if (item != null) {
// item.ReportFileName = this.loader.ReportModel.ReportSettings.FileName;
// }
bool loading = this.loader != null && this.loader.Loading;
LoggingService.Debug("ReportDesignerView: ComponentChanged: " + (e.Component == null ? "<null>" : e.Component.ToString()) + ", Member=" + (e.Member == null ? "<null>" : e.Member.Name) + ", OldValue=" + (e.OldValue == null ? "<null>" : e.OldValue.ToString()) + ", NewValue=" + (e.NewValue == null ? "<null>" : e.NewValue.ToString()) + "; Loading=" + loading + "; Unloading=" + this.unloading);
if (!loading && !unloading) {
this.MakeDirty();
}
// MergeFormChanges();
}
开发者ID:krunalc,项目名称:SharpDevelop,代码行数:15,代码来源:DesignerView.cs
示例8: OnComponentChanged
private void OnComponentChanged(object sender, ComponentChangedEventArgs e)
{
if (e.Component != null && (e.OldValue is ActivityBind && !(e.NewValue is ActivityBind)) ||
(!(e.OldValue is ActivityBind) && e.NewValue is ActivityBind))
TypeDescriptor.Refresh(e.Component);
IReferenceService referenceService = GetService(typeof(IReferenceService)) as IReferenceService;
Activity changedActivity = (referenceService != null) ? referenceService.GetComponent(e.Component) as Activity : e.Component as Activity;
if (changedActivity != null)
{
ActivityDesigner designer = ActivityDesigner.GetDesigner(changedActivity);
if (designer != null)
designer.OnActivityChanged(new ActivityChangedEventArgs(changedActivity, e.Member, e.OldValue, e.NewValue));
}
}
开发者ID:nlh774,项目名称:DotNetReferenceSource,代码行数:15,代码来源:ActivityDesigner.cs
示例9: OnComponentChanged
public override void OnComponentChanged(object sender, ComponentChangedEventArgs ce)
{
base.OnComponentChanged(sender, ce);
MemberDescriptor member = ce.Member;
if ((member != null) && member.GetType().FullName.Equals("System.ComponentModel.ReflectPropertyDescriptor"))
{
PropertyDescriptor descriptor2 = (PropertyDescriptor) member;
if (descriptor2.Name.Equals("Text"))
{
this._textControl.Controls.Clear();
}
}
}
开发者ID:ikvm,项目名称:webmatrix,代码行数:13,代码来源:MobileTextControlDesigner.cs
示例10: OnComponentChanged
public void OnComponentChanged(object component, MemberDescriptor member, object oldValue, object newValue)
{
if (ComponentChanged != null)
{
ComponentChangedEventArgs ce = new ComponentChangedEventArgs(component, member, oldValue, newValue);
try
{
ComponentChanged(this, ce);
}
catch{}
}
}
开发者ID:puentepr,项目名称:thuctapvietinsoft,代码行数:12,代码来源:DesignerHostImpl.cs
示例11: OnComponentChanged
private void OnComponentChanged(object sender, ComponentChangedEventArgs ce)
{
this.dirty = true;
this.unsaved = true;
}
开发者ID:MuffPotter,项目名称:XamarinDesigner,代码行数:5,代码来源:SampleDesignerLoader.cs
示例12: OnComponentChanged
private void OnComponentChanged(object sender, ComponentChangedEventArgs e)
{
Control component = e.Component as Control;
if ((component != null) && component.IsHandleCreated)
{
System.Design.UnsafeNativeMethods.NotifyWinEvent(0x800b, new HandleRef(component, component.Handle), -4, 0);
if (this.frame.Focused)
{
System.Design.UnsafeNativeMethods.NotifyWinEvent(0x8005, new HandleRef(component, component.Handle), -4, 0);
}
}
}
开发者ID:Reegenerator,项目名称:Sample-CustomizeDatasetCS,代码行数:12,代码来源:DocumentDesigner.cs
示例13: OnComponentChanged
public override void OnComponentChanged(object sender, ComponentChangedEventArgs ce)
{
PropertyDescriptor member = ce.Member as PropertyDescriptor;
string key = null;
object propertyValue = null;
object component = ce.Component;
base.OnComponentChanged(sender, ce);
if ((this.ActiveDeviceFilter != null) && (this._overridenValues[this.ActiveDeviceFilter] == null))
{
this._overridenValues[this.ActiveDeviceFilter] = new Hashtable();
}
if (member != null)
{
if (member.Converter is ExpandableObjectConverter)
{
Utils.ChangedSubProperty property = Utils.FindChangedSubProperty(string.Empty, this._mobileControl, member, (this.ActiveDeviceFilter != null) ? ((Hashtable) this._overridenValues[this.ActiveDeviceFilter]) : null, this._defaultValues);
component = property.parentObject;
member = property.propertyDescriptor;
key = property.propertyName;
propertyValue = property.propertyValue;
}
else
{
key = ce.Member.Name;
propertyValue = ce.NewValue;
}
if (!this._isResetting)
{
if ((this.ActiveDeviceFilter != null) && this._deviceSpecificSelectionProvider.DeviceSpecificSelectionProviderEnabled)
{
IAttributeAccessor currentChoice = this.CurrentChoice;
base.IsDirty = true;
if (currentChoice != null)
{
currentChoice.SetAttribute(key, member.Converter.ConvertToInvariantString(propertyValue));
((Hashtable) this._overridenValues[this.ActiveDeviceFilter])[key] = propertyValue;
}
if (propertyValue.Equals(Utils.GetDefaultAttributeValue(member)))
{
IDictionary dictionary = this.CurrentChoice.get_Contents();
dictionary.Remove(key);
((Hashtable) this._overridenValues[this.ActiveDeviceFilter]).Remove(key);
if (((Hashtable) this._overridenValues[this.ActiveDeviceFilter]).Count == 0)
{
this._overridenValues.Remove(this.ActiveDeviceFilter);
}
if (dictionary.Count == 0)
{
this._mobileControl.get_DeviceSpecific().get_Choices().Remove(this.CurrentChoice);
if (this._mobileControl.get_DeviceSpecific().get_Choices().get_Count() == 0)
{
this._mobileControl.set_DeviceSpecific(null);
}
else
{
Utils.SetDeviceSpecificChoice(this._mobileControl, null);
}
}
this._isResetting = true;
member.SetValue(component, this._defaultValues[key]);
this._isResetting = false;
}
}
else
{
this._defaultValues[key] = propertyValue;
}
}
}
}
开发者ID:ikvm,项目名称:webmatrix,代码行数:70,代码来源:MobileControlDesigner.cs
示例14: componentChanged
private void componentChanged(object sender, ComponentChangedEventArgs e)
{
if ((e.Component is ListBoxItem) && this.selectedColumns.Items.Contains(e.Component))
{
this.formIsDirty = true;
}
}
开发者ID:pritesh-mandowara-sp,项目名称:DecompliedDotNetLibraries,代码行数:7,代码来源:DataGridViewColumnCollectionDialog.cs
示例15: OnComponentRemoving
/*
private void OnComponentRemoving (object sender, ComponentEventArgs ce)
// System.Console.WriteLine("RootDesigner:OnComponentRemoving {0}",ce.Component.ToString());
}
private void OnComponentRemoved (object sender, ComponentEventArgs ce)
{
// System.Console.WriteLine("RootDesigner:OnComponentRemoved {0}",ce.Component.ToString());
}
*/
private void OnComponentChanged(object sender, ComponentChangedEventArgs ce)
{
System.Console.WriteLine("RootDesigner:OnComponentChanged {0} from {1} to {2}",ce.Component.ToString(),ce.OldValue,ce.NewValue);
// MemberDescriptor m = ce.Member;
if (ce.Member.Name == "Name") {
AbstractItem item = ce.Component as AbstractItem;
if (item != null) {
item.Name = ce.NewValue.ToString();
}
}
BaseSection section = ce.Component as BaseSection;
if (section != null) {
foreach (BaseSection s in sections)
{
if (s.Name == section.Name) {
s.Size = section.Size;
}
}
RecalculateSections();
}
}
开发者ID:kingjiang,项目名称:SharpDevelopLite,代码行数:36,代码来源:ReportRootDesigner.cs
示例16: OnComponentChanged
protected void OnComponentChanged(object source, ComponentChangedEventArgs args)
{
System.Web.UI.Control component = args.Component as System.Web.UI.Control;
if (component != null)
{
IDesignerHost service = (IDesignerHost) this.GetService(typeof(IDesignerHost));
ControlDesigner designer = service.GetDesigner(component) as ControlDesigner;
if (designer != null)
{
designer.OnComponentChanged(source, args);
}
}
}
开发者ID:ikvm,项目名称:webmatrix,代码行数:13,代码来源:WebFormsDocumentDesigner.cs
示例17: OnComponentChanged
private void OnComponentChanged(object sender, ComponentChangedEventArgs e)
{
if (dsVerbs == null)
return;
if ((e.Component is NeoTabWindow == false) ||
e.Member.Name != "Controls")
return;
NeoTabWindow tw = e.Component as NeoTabWindow;
switch (tw.Controls.Count)
{
case 0:
dsVerbs[0].Enabled = true;
dsVerbs[1].Enabled = false;
break;
default:
dsVerbs[0].Enabled = true;
dsVerbs[1].Enabled = true;
break;
}
}
开发者ID:xieguigang,项目名称:Reference_SharedLib,代码行数:21,代码来源:NeoTabWindowDesigner.cs
示例18: OnComponentChanged
public virtual void OnComponentChanged (object sender, ComponentChangedEventArgs ce) { throw new NotImplementedException (); }
开发者ID:nlhepler,项目名称:mono,代码行数:1,代码来源:ControlDesigner.cs
示例19: configurationsChangeService_ComponentChanged
void configurationsChangeService_ComponentChanged(object sender, ComponentChangedEventArgs e)
{
//you can make changes while in Debug mode, so do not quit if in debug mode
//in debug mode, this function clears the cache immediately, but no rescanning is done because BuildToDos quits in debug mode
bool bHighlightCalled = false;
try
{
mostRecentComponentEvent = DateTime.Now;
System.Diagnostics.Debug.WriteLine("enter " + e.Component.GetType().FullName + " ComponentChanged");
if (e.Member != null)
System.Diagnostics.Debug.WriteLine("member descriptor type: " + e.Member.GetType().FullName);
if (e.Component is Package)
{
if (e.Member == null) //capture when the package configuration editor window is closed
{
IDesignerHost designer = (IDesignerHost)sender;
Window win = FindWindowForDesigner(designer);
if (win == null) return;
HighlightingToDo.ClearCache((Package)e.Component);
BuildToDos(win, (DtsContainer)e.Component);
bHighlightCalled = true;
return;
}
}
else if (e.Component is DtsObject && e.Member != null)
{
if (e.Member.Name == "Expressions" || e.Member.Name == "Name")
{
IDesignerHost designer = (IDesignerHost)sender;
Window win = FindWindowForDesigner(designer);
if (win == null) return;
if (e.Component is Executable)
HighlightingToDo.ClearCache((Executable)e.Component);
else if (e.Component is ConnectionManager)
HighlightingToDo.ClearCache((ConnectionManager)e.Component);
BuildToDos(win, (DtsObject)(e.Component));
bHighlightCalled = true;
return;
}
}
else if (e.Component is Microsoft.DataTransformationServices.PipelineDesignTimeObject)
{
Microsoft.DataTransformationServices.PipelineDesignTimeObject pipelineMetadata = e.Component as Microsoft.DataTransformationServices.PipelineDesignTimeObject;
System.Diagnostics.Debug.WriteLine("edited transform: " + pipelineMetadata.Name);
IDesignerHost designer = (IDesignerHost)sender;
Window win = FindWindowForDesigner(designer);
if (win == null) return;
string sUniqueID = win.ProjectItem.Name + "/" + pipelineMetadata.PipelineTask.ID + "/components/" + pipelineMetadata.ID;
System.Diagnostics.Debug.WriteLine("clearing cache for: " + sUniqueID);
HighlightingToDo.ClearCache(sUniqueID);
BuildToDos(win, pipelineMetadata.PipelineTask, pipelineMetadata.ID);
bHighlightCalled = true;
return;
}
//TODO:
//don't think this is necessary anymore
//else if (e.Component is Microsoft.DataWarehouse.VsIntegration.Designer.NamedCustomTypeDescriptor)
//{
// IDesignerHost designer = (IDesignerHost)sender;
// foreach (Window win in this.ApplicationObject.Windows)
// {
// if (win.Object == designer)
// {
// BuildToDos(win, null);
// bHighlightCalled = true;
// return;
// }
// }
//}
}
catch (Exception ex)
{
System.Diagnostics.Debug.WriteLine("error in configurationsChangeService_ComponentChanged: " + ex.Message + " " + ex.StackTrace);
}
finally
{
try
{
if (e.Component != null)
{
if (e.Member != null)
System.Diagnostics.Debug.WriteLine(e.Component.GetType().FullName + " property updated: " + e.Member.Name + (bHighlightCalled ? " HIGHLIGHTED" : ""));
else
System.Diagnostics.Debug.WriteLine(e.Component.GetType().FullName + " updated" + (bHighlightCalled ? " HIGHLIGHTED" : ""));
}
}
catch { }
}
}
开发者ID:sgtgold,项目名称:bids-helper-extension,代码行数:91,代码来源:ExpressionHighlighterPlugin.cs
示例20: OnComponentChanged
private void OnComponentChanged(object sender, ComponentChangedEventArgs e)
{
UpdateVerbStatus();
}
开发者ID:Cocotteseb,项目名称:Krypton,代码行数:4,代码来源:KryptonRibbonGroupTrackBarDesigner.cs
注:本文中的System.ComponentModel.Design.ComponentChangedEventArgs类示例由纯净天空整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。 |
请发表评论