[mapguide-commits] r9270 - in trunk/MgDev/Desktop/MgDesktop: Services Services/Feature System
svn_mapguide at osgeo.org
svn_mapguide at osgeo.org
Tue Dec 26 06:24:13 PST 2017
Author: jng
Date: 2017-12-26 06:24:13 -0800 (Tue, 26 Dec 2017)
New Revision: 9270
Modified:
trunk/MgDev/Desktop/MgDesktop/Services/Feature/FdoConnectionUtil.cpp
trunk/MgDev/Desktop/MgDesktop/Services/FeatureService.h
trunk/MgDev/Desktop/MgDesktop/Services/ResourceService.cpp
trunk/MgDev/Desktop/MgDesktop/System/Mutex.h
trunk/MgDev/Desktop/MgDesktop/System/PlatformInit.cpp
Log:
Some mg-desktop fixes to better compile on Linux
Modified: trunk/MgDev/Desktop/MgDesktop/Services/Feature/FdoConnectionUtil.cpp
===================================================================
--- trunk/MgDev/Desktop/MgDesktop/Services/Feature/FdoConnectionUtil.cpp 2017-12-26 13:05:45 UTC (rev 9269)
+++ trunk/MgDev/Desktop/MgDesktop/Services/Feature/FdoConnectionUtil.cpp 2017-12-26 14:24:13 UTC (rev 9270)
@@ -200,9 +200,9 @@
FdoPtr<FdoStringElement> company = tokenParts->GetItem(0);
FdoPtr<FdoStringElement> provider = tokenParts->GetItem(1);
- STRING name = company->GetString();
+ STRING name = (FdoString*)company->GetString();
name += L".";
- name += provider->GetString();
+ name += (FdoString*)provider->GetString();
return name;
}
Modified: trunk/MgDev/Desktop/MgDesktop/Services/FeatureService.h
===================================================================
--- trunk/MgDev/Desktop/MgDesktop/Services/FeatureService.h 2017-12-26 13:05:45 UTC (rev 9269)
+++ trunk/MgDev/Desktop/MgDesktop/Services/FeatureService.h 2017-12-26 14:24:13 UTC (rev 9270)
@@ -196,7 +196,7 @@
void UnregisterProvider(CREFSTRING providerName);
- MgFeatureReader *MgFeatureService::GetWfsReader(MgResourceIdentifier *, CREFSTRING, MgStringCollection *, CREFSTRING, CREFSTRING, CREFSTRING);
+ MgFeatureReader *GetWfsReader(MgResourceIdentifier *, CREFSTRING, MgStringCollection *, CREFSTRING, CREFSTRING, CREFSTRING);
EXTERNAL_API:
void PurgeCache(MgResourceIdentifier* resource);
Modified: trunk/MgDev/Desktop/MgDesktop/Services/ResourceService.cpp
===================================================================
--- trunk/MgDev/Desktop/MgDesktop/Services/ResourceService.cpp 2017-12-26 13:05:45 UTC (rev 9269)
+++ trunk/MgDev/Desktop/MgDesktop/Services/ResourceService.cpp 2017-12-26 14:24:13 UTC (rev 9270)
@@ -342,7 +342,7 @@
STRING resType = resource->GetResourceType();
DOMElement* docEl = doc->getDocumentElement();
CHECKNULL(docEl, L"MgdResourceService::SetResource");
- STRING docElName = docEl->getNodeName();
+ STRING docElName = X2W(docEl->getNodeName());
//Now make sure it's the right type of XML document
@@ -368,7 +368,7 @@
}
catch (const SAXParseException& e)
{
- STRING msg = e.getMessage();
+ STRING msg = X2W(e.getMessage());
XMLFileLoc lineNum = e.getLineNumber();
XMLFileLoc colNum = e.getColumnNumber();
@@ -377,10 +377,10 @@
STRING pubIdStr;
if (NULL != pubId)
- pubIdStr = pubId;
+ pubIdStr = X2W(pubId);
STRING sysIdStr;
if (NULL != sysId)
- sysIdStr = sysId;
+ sysIdStr = X2W(sysId);
STRING lineNumStr;
STRING colNumStr;
Modified: trunk/MgDev/Desktop/MgDesktop/System/Mutex.h
===================================================================
--- trunk/MgDev/Desktop/MgDesktop/System/Mutex.h 2017-12-26 13:05:45 UTC (rev 9269)
+++ trunk/MgDev/Desktop/MgDesktop/System/Mutex.h 2017-12-26 14:24:13 UTC (rev 9270)
@@ -69,7 +69,7 @@
~MgdMutex()
{
- pthread_MgdMutex_destroy(&m_CritSect);
+ pthread_mutex_destroy(&m_CritSect);
}
void Initialize()
@@ -77,26 +77,26 @@
if(!m_bInitialized)
{
m_bInitialized = true;
- pthread_MgdMutexattr_init(&m_attributes);
- pthread_MgdMutexattr_settype(&m_attributes, PTHREAD_MgdMutex_RECURSIVE);
- pthread_MgdMutex_init(&m_CritSect, &m_attributes);
- pthread_MgdMutexattr_destroy(&m_attributes);
+ pthread_mutexattr_init(&m_attributes);
+ pthread_mutexattr_settype(&m_attributes, PTHREAD_MUTEX_RECURSIVE);
+ pthread_mutex_init(&m_CritSect, &m_attributes);
+ pthread_mutexattr_destroy(&m_attributes);
}
}
void Enter()
{
- pthread_MgdMutex_lock(&m_CritSect);
+ pthread_mutex_lock(&m_CritSect);
}
void Leave()
{
- pthread_MgdMutex_unlock(&m_CritSect);
+ pthread_mutex_unlock(&m_CritSect);
}
private:
- pthread_MgdMutex_t m_CritSect;
- pthread_MgdMutexattr_t m_attributes;
+ pthread_mutex_t m_CritSect;
+ pthread_mutexattr_t m_attributes;
#endif //_WIN32
Modified: trunk/MgDev/Desktop/MgDesktop/System/PlatformInit.cpp
===================================================================
--- trunk/MgDev/Desktop/MgDesktop/System/PlatformInit.cpp 2017-12-26 13:05:45 UTC (rev 9269)
+++ trunk/MgDev/Desktop/MgDesktop/System/PlatformInit.cpp 2017-12-26 14:24:13 UTC (rev 9270)
@@ -127,7 +127,8 @@
{
if (MgFileUtil::IsDirectory(mentorDictPath))
{
- setenv("MENTOR_DICTIONARY_PATH", mentorDictPath.c_str(), 1);
+ std::string mbMentorDictPath = MgUtil::WideCharToMultiByte(mentorDictPath);
+ setenv("MENTOR_DICTIONARY_PATH", mbMentorDictPath.c_str(), 1);
}
}
#endif
More information about the mapguide-commits
mailing list