bug 241061 Action name exported by mozilla is messed up in at-poke

r = pkw@us.ibm.com
sr= henry.jia@sun.com
This commit is contained in:
louie.zhao%sun.com 2004-05-18 03:31:05 +00:00
Родитель ac2d130bc6
Коммит d5492eb87b
2 изменённых файлов: 8 добавлений и 13 удалений

Просмотреть файл

@ -139,16 +139,11 @@ getNameCB(AtkAction *aAction, gint aActionIndex)
accWrap->GetMaiInterface(MAI_INTERFACE_ACTION));
NS_ENSURE_TRUE(action, nsnull);
const char *name = action->GetName();
if (!name || !*name) {
nsAutoString autoStr;
nsresult rv = accWrap->GetActionName(aActionIndex, autoStr);
NS_ENSURE_SUCCESS(rv, nsnull);
action->SetName(autoStr);
name = action->GetName();
}
return name;
nsAutoString autoStr;
nsresult rv = accWrap->GetActionName(aActionIndex, autoStr);
NS_ENSURE_SUCCESS(rv, nsnull);
action->SetName(autoStr);
return action->GetName();
}
const gchar *

Просмотреть файл

@ -54,16 +54,16 @@ public:
virtual const GInterfaceInfo *GetInterfaceInfo();
const char *GetName() {
return NS_ConvertUCS2toUTF8(mName).get();
return mName.get();
}
void SetName(nsAString &aString) { mName = aString; }
void SetName(nsAString &aString) { mName = NS_ConvertUCS2toUTF8(aString); }
const char *GetKeyBinding() {
return NS_ConvertUCS2toUTF8(mKeyBinding).get();
}
void SetKeyBinding(nsAString &aString) { mKeyBinding = aString; }
private:
nsString mName;
nsCString mName;
nsString mKeyBinding;
};