29 #include <sbIPropertyArray.h>
30 #include <sbIPropertyManager.h>
31 #include <nsITreeView.h>
34 #include <nsNetUtil.h>
35 #include <nsServiceManagerUtils.h>
36 #include <nsUnicharUtils.h>
45 const nsAString& aDisplayName,
46 const nsAString& aLocalizationKey,
47 const PRBool aRemoteReadable,
48 const PRBool aRemoteWritable,
49 const PRBool aUserViewable,
50 const PRBool aUserEditable,
51 const nsAString& aUrlPropertyID)
54 mDisplayName = aDisplayName;
55 mLocalizationKey = aLocalizationKey;
56 mUserViewable = aUserViewable;
57 mUserEditable = aUserEditable;
58 mRemoteReadable = aRemoteReadable;
59 mRemoteWritable = aRemoteWritable;
60 mUrlPropertyID = aUrlPropertyID;
61 mType.AssignLiteral(
"image");
62 mSuppressSelect = PR_TRUE;
71 NS_ENSURE_SUCCESS(rv, rv);
79 sbImageLinkPropertyInfo::GetImageSrc(
const nsAString&
aValue,
82 if(!aValue.IsEmpty() &&
83 !aValue.LowerCaseEqualsLiteral(
"default")) {
94 sbImageLinkPropertyInfo::GetProgressMode(
const nsAString& aValue,
97 NS_ENSURE_ARG_POINTER(_retval);
98 *_retval = nsITreeView::PROGRESS_NONE;
103 sbImageLinkPropertyInfo::GetCellValue(
const nsAString& aValue,
111 sbImageLinkPropertyInfo::GetRowProperties(
const nsAString& aValue,
119 sbImageLinkPropertyInfo::GetCellProperties(
const nsAString& aValue,
122 if(aValue.IsEmpty()) {
123 _retval.AssignLiteral(
"image noLink");
127 _retval.AssignLiteral(
"image link");
133 sbImageLinkPropertyInfo::GetColumnType(nsAString& _retval)
135 _retval.AssignLiteral(
"text");
142 sbImageLinkPropertyInfo::GetSuppressSelect(PRBool* aSuppressSelect)
144 NS_ENSURE_ARG_POINTER(aSuppressSelect);
150 sbImageLinkPropertyInfo::SetSuppressSelect(PRBool aSuppressSelect)
157 sbImageLinkPropertyInfo::IsDisabled(
const nsAString& aCurrentValue,
160 NS_ENSURE_ARG_POINTER(_retval);
166 sbImageLinkPropertyInfo::HitTest(
const nsAString& aCurrentValue,
167 const nsAString& aPart,
174 NS_ENSURE_ARG_POINTER(_retval);
175 *_retval = aPart.EqualsLiteral(
"image");
180 sbImageLinkPropertyInfo::GetValueForClick(
const nsAString& aCurrentValue,
187 return NS_ERROR_NOT_IMPLEMENTED;
197 PRBool *_retval NS_OUTPARAM)
199 NS_ENSURE_ARG_POINTER(_retval);
217 sbImageLinkPropertyInfo::GetUrlProperty(nsAString& _retval)
225 sbImageLinkPropertyInfo::GetPreventNavigation(
const nsAString& aImageValue,
226 const nsAString& aUrlValue,
229 NS_ENSURE_ARG_POINTER(_retval);
231 *_retval = aImageValue.IsEmpty() ||
NS_IMPL_ISUPPORTS_INHERITED3(sbImageLinkPropertyInfo, sbImmutablePropertyInfo, sbIImageLinkPropertyInfo, sbIClickablePropertyInfo, sbITreeViewPropertyInfo) sbImageLinkPropertyInfo
The property information specific to clickable properties.
NS_IMETHOD Format(const nsAString &aValue, nsAString &_retval)
The property information specific to image link properties.