Skip to content
Projeler
Gruplar
Parçacıklar
Yardım
Yükleniyor...
Oturum aç / Kaydol
Gezinmeyi değiştir
C
core
Proje
Proje
Ayrıntılar
Etkinlik
Cycle Analytics
Depo (repository)
Depo (repository)
Dosyalar
Kayıtlar (commit)
Dallar (branch)
Etiketler
Katkıda bulunanlar
Grafik
Karşılaştır
Grafikler
Konular (issue)
0
Konular (issue)
0
Liste
Pano
Etiketler
Kilometre Taşları
Birleştirme (merge) Talepleri
0
Birleştirme (merge) Talepleri
0
CI / CD
CI / CD
İş akışları (pipeline)
İşler
Zamanlamalar
Grafikler
Paketler
Paketler
Wiki
Wiki
Parçacıklar
Parçacıklar
Üyeler
Üyeler
Collapse sidebar
Close sidebar
Etkinlik
Grafik
Grafikler
Yeni bir konu (issue) oluştur
İşler
Kayıtlar (commit)
Konu (issue) Panoları
Kenar çubuğunu aç
LibreOffice
core
Commits
b6f6cf85
Kaydet (Commit)
b6f6cf85
authored
Kas 10, 2015
tarafından
Stephan Bergmann
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Eposta Yamaları
Sade Fark
loplugin:nullptr (automatic rewrite; Mac-specific code)
Change-Id: Iaa14c583c55c3582e33a1d073ea92b388cd6f3a4
üst
b6f1be10
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
14 additions
and
14 deletions
+14
-14
localebackend.cxx
shell/source/backends/localebe/localebackend.cxx
+6
-6
macbackend.mm
shell/source/backends/macbe/macbackend.mm
+6
-6
macbecdef.cxx
shell/source/backends/macbe/macbecdef.cxx
+2
-2
No files found.
shell/source/backends/localebe/localebackend.cxx
Dosyayı görüntüle @
b6f6cf85
...
@@ -97,14 +97,14 @@ namespace /* private */
...
@@ -97,14 +97,14 @@ namespace /* private */
CFStringRef
ImplGetAppPreference
(
const
char
*
pref
)
CFStringRef
ImplGetAppPreference
(
const
char
*
pref
)
{
{
CFStringRef
csPref
=
CFStringCreateWithCString
(
NULL
,
pref
,
kCFStringEncodingASCII
);
CFStringRef
csPref
=
CFStringCreateWithCString
(
nullptr
,
pref
,
kCFStringEncodingASCII
);
CFStringGuard
csRefGuard
(
csPref
);
CFStringGuard
csRefGuard
(
csPref
);
CFTypeRef
ref
=
CFPreferencesCopyAppValue
(
csPref
,
kCFPreferencesCurrentApplication
);
CFTypeRef
ref
=
CFPreferencesCopyAppValue
(
csPref
,
kCFPreferencesCurrentApplication
);
CFTypeRefGuard
refGuard
(
ref
);
CFTypeRefGuard
refGuard
(
ref
);
if
(
ref
==
NULL
)
if
(
ref
==
nullptr
)
return
NULL
;
return
nullptr
;
CFStringRef
sref
=
(
CFGetTypeID
(
ref
)
==
CFArrayGetTypeID
())
?
static_cast
<
CFStringRef
>
(
CFArrayGetValueAtIndex
(
static_cast
<
CFArrayRef
>
(
ref
),
0
))
:
static_cast
<
CFStringRef
>
(
ref
);
CFStringRef
sref
=
(
CFGetTypeID
(
ref
)
==
CFArrayGetTypeID
())
?
static_cast
<
CFStringRef
>
(
CFArrayGetValueAtIndex
(
static_cast
<
CFArrayRef
>
(
ref
),
0
))
:
static_cast
<
CFStringRef
>
(
ref
);
...
@@ -122,14 +122,14 @@ namespace /* private */
...
@@ -122,14 +122,14 @@ namespace /* private */
OUStringBuffer
aLocaleBuffer
;
OUStringBuffer
aLocaleBuffer
;
aLocaleBuffer
.
append
(
"en-US"
);
// initialize with fallback value
aLocaleBuffer
.
append
(
"en-US"
);
// initialize with fallback value
if
(
sref
!=
NULL
)
if
(
sref
!=
nullptr
)
{
{
// split the string into substrings; the first two (if there are two) substrings
// split the string into substrings; the first two (if there are two) substrings
// are language and country
// are language and country
CFArrayRef
subs
=
CFStringCreateArrayBySeparatingStrings
(
NULL
,
sref
,
CFSTR
(
"_"
));
CFArrayRef
subs
=
CFStringCreateArrayBySeparatingStrings
(
nullptr
,
sref
,
CFSTR
(
"_"
));
CFArrayGuard
subsGuard
(
subs
);
CFArrayGuard
subsGuard
(
subs
);
if
(
subs
!=
NULL
)
if
(
subs
!=
nullptr
)
{
{
aLocaleBuffer
.
setLength
(
0
);
// clear buffer which still contains fallback value
aLocaleBuffer
.
setLength
(
0
);
// clear buffer which still contains fallback value
...
...
shell/source/backends/macbe/macbackend.mm
Dosyayı görüntüle @
b6f6cf85
...
@@ -72,7 +72,7 @@ bool GetProxySetting(ServiceType sType, char *host, size_t hostSize, UInt16 *por
...
@@ -72,7 +72,7 @@ bool GetProxySetting(ServiceType sType, char *host, size_t hostSize, UInt16 *por
CFNumberRef portNum;
CFNumberRef portNum;
int portInt;
int portInt;
proxyDict = SCDynamicStoreCopyProxies(
NULL
);
proxyDict = SCDynamicStoreCopyProxies(
nullptr
);
if (!proxyDict)
if (!proxyDict)
return false;
return false;
...
@@ -100,7 +100,7 @@ bool GetProxySetting(ServiceType sType, char *host, size_t hostSize, UInt16 *por
...
@@ -100,7 +100,7 @@ bool GetProxySetting(ServiceType sType, char *host, size_t hostSize, UInt16 *por
enableNum = static_cast<CFNumberRef>(CFDictionaryGetValue( proxyDict,
enableNum = static_cast<CFNumberRef>(CFDictionaryGetValue( proxyDict,
proxiesEnable ));
proxiesEnable ));
result = (enableNum !=
NULL
) && (CFGetTypeID(enableNum) == CFNumberGetTypeID());
result = (enableNum !=
nullptr
) && (CFGetTypeID(enableNum) == CFNumberGetTypeID());
if (result)
if (result)
result = CFNumberGetValue(enableNum, kCFNumberIntType, &enable) && (enable != 0);
result = CFNumberGetValue(enableNum, kCFNumberIntType, &enable) && (enable != 0);
...
@@ -111,7 +111,7 @@ bool GetProxySetting(ServiceType sType, char *host, size_t hostSize, UInt16 *por
...
@@ -111,7 +111,7 @@ bool GetProxySetting(ServiceType sType, char *host, size_t hostSize, UInt16 *por
hostStr = static_cast<CFStringRef>(CFDictionaryGetValue( proxyDict,
hostStr = static_cast<CFStringRef>(CFDictionaryGetValue( proxyDict,
proxiesProxy ));
proxiesProxy ));
result = (hostStr !=
NULL
) && (CFGetTypeID(hostStr) == CFStringGetTypeID());
result = (hostStr !=
nullptr
) && (CFGetTypeID(hostStr) == CFStringGetTypeID());
}
}
if (result)
if (result)
...
@@ -123,7 +123,7 @@ bool GetProxySetting(ServiceType sType, char *host, size_t hostSize, UInt16 *por
...
@@ -123,7 +123,7 @@ bool GetProxySetting(ServiceType sType, char *host, size_t hostSize, UInt16 *por
portNum = static_cast<CFNumberRef>(CFDictionaryGetValue( proxyDict,
portNum = static_cast<CFNumberRef>(CFDictionaryGetValue( proxyDict,
proxiesPort ));
proxiesPort ));
result = (portNum !=
NULL
) && (CFGetTypeID(portNum) == CFNumberGetTypeID());
result = (portNum !=
nullptr
) && (CFGetTypeID(portNum) == CFNumberGetTypeID());
}
}
else
else
{
{
...
@@ -396,10 +396,10 @@ css::uno::Any MacOSXBackend::getPropertyValue(
...
@@ -396,10 +396,10 @@ css::uno::Any MacOSXBackend::getPropertyValue(
rtl::OUString aProxyBypassList;
rtl::OUString aProxyBypassList;
CFArrayRef rExceptionsList;
CFArrayRef rExceptionsList;
CFDictionaryRef rProxyDict = SCDynamicStoreCopyProxies(
NULL
);
CFDictionaryRef rProxyDict = SCDynamicStoreCopyProxies(
nullptr
);
if (!rProxyDict)
if (!rProxyDict)
rExceptionsList =
0
;
rExceptionsList =
nullptr
;
else
else
rExceptionsList = static_cast<CFArrayRef>(CFDictionaryGetValue(rProxyDict, kSCPropNetProxiesExceptionsList));
rExceptionsList = static_cast<CFArrayRef>(CFDictionaryGetValue(rProxyDict, kSCPropNetProxiesExceptionsList));
...
...
shell/source/backends/macbe/macbecdef.cxx
Dosyayı görüntüle @
b6f6cf85
...
@@ -43,10 +43,10 @@ static const cppu::ImplementationEntry kImplementations_entries[] =
...
@@ -43,10 +43,10 @@ static const cppu::ImplementationEntry kImplementations_entries[] =
MacOSXBackend
::
getBackendName
,
MacOSXBackend
::
getBackendName
,
MacOSXBackend
::
getBackendServiceNames
,
MacOSXBackend
::
getBackendServiceNames
,
cppu
::
createSingleComponentFactory
,
cppu
::
createSingleComponentFactory
,
NULL
,
nullptr
,
0
0
},
},
{
0
,
0
,
0
,
0
,
0
,
0
}
{
nullptr
,
nullptr
,
nullptr
,
nullptr
,
nullptr
,
0
}
};
};
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment