Module: wine
Branch: master
Commit: 8f78ff29612c70992c1e0d2aaf38f694d12e04da
URL: http://source.winehq.org/git/wine.git/?a=commit;h=8f78ff29612c70992c1e0d2aa…
Author: Vladimir Pankratov <scriptkid(a)mail.ru>
Date: Wed Sep 2 15:53:44 2009 +0500
jscript: Add Russian translation.
---
dlls/jscript/Makefile.in | 1 +
dlls/jscript/jscript_Ru.rc | 44 ++++++++++++++++++++++++++++++++++++++++++++
2 files changed, 45 insertions(+), 0 deletions(-)
diff --git a/dlls/jscript/Makefile.in b/dlls/jscript/Makefile.in
index e1e164f..241ef4b 100644
--- a/dlls/jscript/Makefile.in
+++ b/dlls/jscript/Makefile.in
@@ -12,6 +12,7 @@ RC_SRCS = \
jscript_Lt.rc \
jscript_Nl.rc \
jscript_Pt.rc \
+ jscript_Ru.rc \
rsrc.rc
C_SRCS = \
diff --git a/dlls/jscript/jscript_Ru.rc b/dlls/jscript/jscript_Ru.rc
new file mode 100644
index 0000000..998c715
--- /dev/null
+++ b/dlls/jscript/jscript_Ru.rc
@@ -0,0 +1,44 @@
+/*
+ * Copyright 2009 Vladimir Pankratov
+ *
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License as published by the Free Software Foundation; either
+ * version 2.1 of the License, or (at your option) any later version.
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this library; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
+ */
+
+#include "resource.h"
+
+/* UTF-8 */
+#pragma code_page(65001)
+
+LANGUAGE LANG_RUSSIAN, SUBLANG_DEFAULT
+
+STRINGTABLE DISCARDABLE
+{
+ IDS_TO_PRIMITIVE "Ошибка конвертирования обьекта в примитивный тип"
+ IDS_INVALID_CALL_ARG "Неверный вызов процедуры или аргумент"
+ IDS_NO_PROPERTY "Обьект не поддерживает это свойство или метод"
+ IDS_ARG_NOT_OPT "Отсутствует обязательный аргумент"
+ IDS_SYNTAX_ERROR "Синтаксическая ошибка"
+ IDS_SEMICOLON "Ожидается ';'"
+ IDS_LBRACKET "Ожидается '('"
+ IDS_RBRACKET "Ожидается ')'"
+ IDS_UNTERMINATED_STR "Незавершённая строковая константа"
+ IDS_NOT_FUNC "Ожидается функция"
+ IDS_NOT_DATE "'[object]' не обьект типа 'date'"
+ IDS_NOT_NUM "Ожидается число"
+ IDS_ILLEGAL_ASSIGN "Неверное присваивание"
+ IDS_UNDEFINED "'|' не определён"
+ IDS_NOT_BOOL "Ожидается обьект типа 'bool'"
+ IDS_INVALID_LENGTH "Длиной массива должно быть конечное положительное число"
+}
Module: wine
Branch: master
Commit: bb457f7ffd3d6957861f96846de0e1115100368e
URL: http://source.winehq.org/git/wine.git/?a=commit;h=bb457f7ffd3d6957861f96846…
Author: Roderick Colenbrander <thunderbird2k(a)gmail.com>
Date: Wed Sep 2 15:00:54 2009 +0200
winex11: Use ColorShifts in get_xrender_format_from_pdevice.
---
dlls/winex11.drv/xrender.c | 43 ++++++++++++++++++++++++++++++-------------
1 files changed, 30 insertions(+), 13 deletions(-)
diff --git a/dlls/winex11.drv/xrender.c b/dlls/winex11.drv/xrender.c
index a5ea946..a0f9b7b 100644
--- a/dlls/winex11.drv/xrender.c
+++ b/dlls/winex11.drv/xrender.c
@@ -429,21 +429,38 @@ static WineXRenderFormat *get_xrender_format(WXRFormat format)
static WineXRenderFormat *get_xrender_format_from_pdevice(X11DRV_PDEVICE *physDev)
{
- WXRFormat format;
-
- switch(physDev->depth)
+ if(physDev->depth == 1)
+ return get_xrender_format(WXR_FORMAT_MONO);
+ /* physDevs of a depth <=8, don't have color_shifts set and XRender can't handle those except for 1-bit */
+ else if(!physDev->color_shifts)
+ return default_format;
+ else
{
- case 1:
- format = WXR_FORMAT_MONO;
- break;
- default:
- /* For now fall back to the format of the default visual.
- In the future we should check if we are using a DDB/DIB and what exact format we need.
- */
- return default_format;
- }
+ int redMask=0, greenMask=0, blueMask=0;
+ int i;
+ ColorShifts *shifts = physDev->color_shifts;
+
+ redMask = shifts->physicalRed.max << shifts->physicalRed.shift;
+ greenMask = shifts->physicalGreen.max << shifts->physicalGreen.shift;
+ blueMask = shifts->physicalBlue.max << shifts->physicalBlue.shift;
+
+ /* Try to locate a format which matches the specification of the dibsection. */
+ for(i = 0; i < (sizeof(wxr_formats_template) / sizeof(wxr_formats_template[0])); i++)
+ {
+ if( physDev->depth == wxr_formats_template[i].depth &&
+ redMask == (wxr_formats_template[i].redMask << wxr_formats_template[i].red) &&
+ greenMask == (wxr_formats_template[i].greenMask << wxr_formats_template[i].green) &&
+ blueMask == (wxr_formats_template[i].blueMask << wxr_formats_template[i].blue) )
- return get_xrender_format(format);
+ {
+ /* When we reach this stage the format was found in our template table but this doesn't mean that
+ * the Xserver also supports this format (e.g. its depth might be too low). The call below verifies that.
+ */
+ return get_xrender_format(wxr_formats_template[i].wxr_format);
+ }
+ }
+ }
+ return NULL;
}
static BOOL fontcmp(LFANDSIZE *p1, LFANDSIZE *p2)