Merge branch 'master' of github.com:supertuxkart/stk-code
This commit is contained in:
@@ -433,7 +433,7 @@ if(STK_ASSETS_DIR AND CHECK_ASSETS)
|
||||
install(DIRECTORY ${STK_ASSETS_DIR} DESTINATION ${STK_INSTALL_DATA_DIR}/data PATTERN ".svn" EXCLUDE PATTERN ".git" EXCLUDE)
|
||||
endif()
|
||||
install(FILES ${STK_DATA_DIR}/supertuxkart.desktop DESTINATION share/applications)
|
||||
install(FILES data/supertuxkart_32.png DESTINATION share/icons/hicolor/32x32 RENAME supertuxkart.png)
|
||||
install(FILES data/supertuxkart_128.png DESTINATION share/icons/hicolor/128x128 RENAME supertuxkart.png)
|
||||
install(FILES data/supertuxkart_32.png DESTINATION share/icons/hicolor/32x32/apps RENAME supertuxkart.png)
|
||||
install(FILES data/supertuxkart_128.png DESTINATION share/icons/hicolor/128x128/apps RENAME supertuxkart.png)
|
||||
install(FILES data/supertuxkart_32.png data/supertuxkart_128.png DESTINATION share/pixmaps)
|
||||
install(FILES data/supertuxkart.appdata.xml DESTINATION share/appdata)
|
||||
|
||||
@@ -10,6 +10,9 @@
|
||||
<card contains="Mesa" os="linux" version="<10.3" disable="BufferStorage"/>
|
||||
<card contains="Mesa" os="linux" version="<10.3" disable="DriverRecentEnough"/>
|
||||
<card contains="Mesa" os="linux" version="<10.6" disable="GeometryShader4"/>
|
||||
<card contains="Gallium" os="linux" version="<10.3" disable="BufferStorage"/>
|
||||
<card contains="Gallium" os="linux" version="<10.3" disable="DriverRecentEnough"/>
|
||||
<card contains="Gallium" os="linux" version="<10.6" disable="GeometryShader4"/>
|
||||
<card contains="Radeon" version="<14.300" disable="DriverRecentEnough"/>
|
||||
</graphical-restrictions>
|
||||
|
||||
|
||||
@@ -11,6 +11,7 @@ extern bool GLContextDebugBit;
|
||||
|
||||
#include <stdio.h>
|
||||
#include <stdlib.h>
|
||||
#include <unistd.h>
|
||||
#include <sys/utsname.h>
|
||||
#include <time.h>
|
||||
#include "IEventReceiver.h"
|
||||
|
||||
@@ -614,6 +614,9 @@ void IrrDriver::renderSolidSecondPass()
|
||||
glMakeTextureHandleResidentARB(DepthHandle);
|
||||
}
|
||||
|
||||
if (CVS->supportsIndirectInstancingRendering())
|
||||
glBindBuffer(GL_DRAW_INDIRECT_BUFFER, SolidPassCmd::getInstance()->drawindirectcmd);
|
||||
|
||||
{
|
||||
ScopedGPUTimer Timer(getGPUTimer(Q_SOLID_PASS2));
|
||||
|
||||
|
||||
@@ -121,7 +121,7 @@ DictionaryManager::get_dictionary(const Language& language)
|
||||
{
|
||||
std::vector<std::string> files = filesystem->open_directory(*p);
|
||||
|
||||
std::string best_filename;
|
||||
std::string best_filename = "";
|
||||
int best_score = 0;
|
||||
|
||||
for(std::vector<std::string>::iterator filename = files.begin(); filename != files.end(); filename++)
|
||||
@@ -130,7 +130,7 @@ DictionaryManager::get_dictionary(const Language& language)
|
||||
if (has_suffix(*filename, ".po"))
|
||||
{ // ignore anything that isn't a .po file
|
||||
|
||||
Language po_language = Language::from_env(convertFilename2Language(*filename));
|
||||
Language po_language = Language::from_env(convertFilename2Language(*filename));
|
||||
|
||||
if (!po_language)
|
||||
{
|
||||
@@ -194,7 +194,12 @@ DictionaryManager::get_languages()
|
||||
{
|
||||
if (has_suffix(*file, ".po"))
|
||||
{
|
||||
languages.insert(Language::from_env(file->substr(0, file->size()-3)));
|
||||
Language po_language = Language::from_env(file->substr(0, file->size()-3));
|
||||
|
||||
if (po_language)
|
||||
{
|
||||
languages.insert(po_language);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -58,16 +58,26 @@ PluralForms::from_string(const std::string& str)
|
||||
plural_forms["Plural-Forms:nplurals=2;plural=(n!=1);"] = PluralForms(2, plural2_1);
|
||||
plural_forms["Plural-Forms:nplurals=2;plural=n!=1;"] = PluralForms(2, plural2_1);
|
||||
plural_forms["Plural-Forms:nplurals=2;plural=(n>1);"] = PluralForms(2, plural2_2);
|
||||
plural_forms["Plural-Forms:nplurals=2;plural=n>1;"] = PluralForms(2, plural2_2);
|
||||
plural_forms["Plural-Forms:nplurals=2;plural=(n==1||n%10==1?0:1);"] = PluralForms(2, plural2_mk);
|
||||
plural_forms["Plural-Forms:nplurals=2;plural=n==1||n%10==1?0:1;"] = PluralForms(2, plural2_mk);
|
||||
plural_forms["Plural-Forms:nplurals=3;plural=n%10==1&&n%100!=11?0:n!=0?1:2);"] = PluralForms(2, plural3_lv);
|
||||
plural_forms["Plural-Forms:nplurals=3;plural=(n%10==1&&n%100!=11?0:n!=0?1:2);"] = PluralForms(2, plural3_lv);
|
||||
plural_forms["Plural-Forms:nplurals=3;plural=n%10==1&&n%100!=11?0:n!=0?1:2;"] = PluralForms(2, plural3_lv);
|
||||
plural_forms["Plural-Forms:nplurals=3;plural=(n==1?0:n==2?1:2);"] = PluralForms(3, plural3_ga);
|
||||
plural_forms["Plural-Forms:nplurals=3;plural=n==1?0:n==2?1:2;"] = PluralForms(3, plural3_ga);
|
||||
plural_forms["Plural-Forms:nplurals=3;plural=(n%10==1&&n%100!=11?0:n%10>=2&&(n%100<10||n%100>=20)?1:2);"] = PluralForms(3, plural3_lt);
|
||||
plural_forms["Plural-Forms:nplurals=3;plural=n%10==1&&n%100!=11?0:n%10>=2&&(n%100<10||n%100>=20)?1:2;"] = PluralForms(3, plural3_lt);
|
||||
plural_forms["Plural-Forms:nplurals=3;plural=(n%10==1&&n%100!=11?0:n%10>=2&&n%10<=4&&(n%100<10||n%100>=20)?1:2);"] = PluralForms(3, plural3_1);
|
||||
plural_forms["Plural-Forms:nplurals=3;plural=n%10==1&&n%100!=11?0:n%10>=2&&n%10<=4&&(n%100<10||n%100>=20)?1:2;"] = PluralForms(3, plural3_1);
|
||||
plural_forms["Plural-Forms:nplurals=3;plural=((n==1)?0:(n>=2&&n<=4)?1:2);"] = PluralForms(3, plural3_sk);
|
||||
plural_forms["Plural-Forms:nplurals=3;plural=(n==1)?0:(n>=2&&n<=4)?1:2;"] = PluralForms(3, plural3_sk);
|
||||
plural_forms["Plural-Forms:nplurals=3;plural=(n==1?0:n%10>=2&&n%10<=4&&(n%100<10||n%100>=20)?1:2);"] = PluralForms(3, plural3_pl);
|
||||
plural_forms["Plural-Forms:nplurals=3;plural=n==1?0:n%10>=2&&n%10<=4&&(n%100<10||n%100>=20)?1:2;"] = PluralForms(3, plural3_pl);
|
||||
plural_forms["Plural-Forms:nplurals=3;plural=(n%100==1?0:n%100==2?1:n%100==3||n%100==4?2:3);"] = PluralForms(3, plural3_sl);
|
||||
|
||||
plural_forms["Plural-Forms:nplurals=3;plural=n%100==1?0:n%100==2?1:n%100==3||n%100==4?2:3;"] = PluralForms(3, plural3_sl);
|
||||
plural_forms["Plural-Forms:nplurals=4;plural=(n==1?0:n==2?1:n>=3&&n<=10?2:3);"]=PluralForms(4, plural4_ar);
|
||||
plural_forms["Plural-Forms:nplurals=4;plural=n==1?0:n==2?1:n>=3&&n<=10?2:3;"]=PluralForms(4, plural4_ar);
|
||||
plural_forms["Plural-Forms:nplurals=4;plural=((n==1||n==11)?0:(n==2||n==12)?1:(n>2&&n<20)?2:3);"]=PluralForms(4, plural4_gd);
|
||||
plural_forms["Plural-Forms:nplurals=4;plural=(n==1||n==11)?0:(n==2||n==12)?1:(n>2&&n<20)?2:3;"]=PluralForms(4, plural4_gd);
|
||||
}
|
||||
|
||||
|
||||
@@ -95,27 +95,22 @@ wchar_t* utf8_to_wide(const char* input)
|
||||
// ----------------------------------------------------------------------------
|
||||
Translations::Translations() //: m_dictionary_manager("UTF-16")
|
||||
{
|
||||
|
||||
m_dictionary_manager.add_directory(
|
||||
file_manager->getAsset(FileManager::TRANSLATION,""));
|
||||
|
||||
if (g_language_list.size() == 0)
|
||||
{
|
||||
std::set<std::string> flist;
|
||||
file_manager->listFiles(flist,
|
||||
file_manager->getAsset(FileManager::TRANSLATION,""));
|
||||
|
||||
std::set<Language> languages = m_dictionary_manager.get_languages();
|
||||
|
||||
// English is always there but won't be found on file system
|
||||
g_language_list.push_back("en");
|
||||
|
||||
std::set<std::string>::iterator it;
|
||||
for ( it=flist.begin() ; it != flist.end(); it++ )
|
||||
|
||||
std::set<Language>::iterator it;
|
||||
for (it = languages.begin(); it != languages.end(); it++)
|
||||
{
|
||||
if (StringUtils::hasSuffix(*it, "po"))
|
||||
{
|
||||
g_language_list.push_back
|
||||
(m_dictionary_manager.convertFilename2Language(*it) );
|
||||
// printf("Lang : <%s>\n", (*it).c_str());
|
||||
}
|
||||
} // for it in flist
|
||||
} // if (g_language_list.size() == 0)
|
||||
g_language_list.push_back((*it).str());
|
||||
}
|
||||
}
|
||||
|
||||
// LC_ALL does not work, sscanf will then not always be able
|
||||
// to scan for example: s=-1.1,-2.3,-3.3 correctly, which is
|
||||
@@ -149,9 +144,6 @@ Translations::Translations() //: m_dictionary_manager("UTF-16")
|
||||
textdomain (PACKAGE);
|
||||
*/
|
||||
|
||||
m_dictionary_manager.add_directory(
|
||||
file_manager->getAsset(FileManager::TRANSLATION,""));
|
||||
|
||||
/*
|
||||
const std::set<Language>& languages = m_dictionary_manager.get_languages();
|
||||
Log::info("Translatings", "Number of languages: %d", languages.size());
|
||||
|
||||
Reference in New Issue
Block a user