| 12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455 |
- /**
- * Namespace: System.Web.UI.WebControls
- * Class: TargetConverter
- *
- * Author: Gaurav Vaish
- * Maintainer: [email protected]
- * Contact: <[email protected]>, <[email protected]>
- * Implementation: yes
- * Status: 100%
- *
- * (C) Gaurav Vaish (2002)
- */
- using System;
- using System.ComponentModel;
- using System.Web;
- using System.Web.UI;
- namespace System.Web.UI.WebControls
- {
- public class TargetConverter : StringConverter
- {
- private StandardValuesCollection standardValues;
- private string[] values = {
- "_parent",
- "_self",
- "_blank",
- "_search",
- "_top"
- };
-
- public TargetConverter(): base()
- {
- }
-
- public override StandardValuesCollection GetStandardValues(ITypeDescriptorContext context)
- {
- if(standardValues == null)
- {
- standardValues = new StandardValuesCollection(values);
- }
- return standardValues;
- }
-
- public override bool GetStandardValuesExclusive(ITypeDescriptorContext context)
- {
- return false;
- }
-
- public override bool GetStandardValuesSupported(ITypeDescriptorContext context)
- {
- return true;
- }
- }
- }
|