This commit is contained in:
Philip Chee 2011-04-25 02:19:44 +08:00
Родитель be38c51383 f3e044b88a
Коммит a986a2c9c7
2 изменённых файлов: 26 добавлений и 0 удалений

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

@ -3201,6 +3201,27 @@ NS_IMETHODIMP DocumentViewerImpl::GetBidiSupport(PRUint8* aSupport)
return NS_OK;
}
NS_IMETHODIMP DocumentViewerImpl::SetBidiCharacterSet(PRUint8 aCharacterSet)
{
PRUint32 bidiOptions;
GetBidiOptions(&bidiOptions);
SET_BIDI_OPTION_CHARACTERSET(bidiOptions, aCharacterSet);
SetBidiOptions(bidiOptions);
return NS_OK;
}
NS_IMETHODIMP DocumentViewerImpl::GetBidiCharacterSet(PRUint8* aCharacterSet)
{
PRUint32 bidiOptions;
if (aCharacterSet) {
GetBidiOptions(&bidiOptions);
*aCharacterSet = GET_BIDI_OPTION_CHARACTERSET(bidiOptions);
}
return NS_OK;
}
NS_IMETHODIMP DocumentViewerImpl::SetBidiOptions(PRUint32 aBidiOptions)
{
if (mPresContext) {

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

@ -764,6 +764,11 @@ nsPresContext::GetUserPreferences()
GET_BIDI_OPTION_SUPPORT(bidiOptions));
SET_BIDI_OPTION_SUPPORT(bidiOptions, prefInt);
prefInt =
nsContentUtils::GetIntPref(IBMBIDI_CHARSET_STR,
GET_BIDI_OPTION_CHARACTERSET(bidiOptions));
SET_BIDI_OPTION_CHARACTERSET(bidiOptions, prefInt);
// We don't need to force reflow: either we are initializing a new
// prescontext or we are being called from UpdateAfterPreferencesChanged()
// which triggers a reflow anyway.