Correct type cast.
This commit is contained in:
parent
bb51401c4c
commit
8d8c7ce6ad
2 changed files with 4 additions and 3 deletions
|
@ -65,7 +65,8 @@ bool Browser::RemoveAsDefaultProtocolClient(const std::string& protocol,
|
||||||
// Apple's defaults first, so we'll use the first option that isn't our bundle
|
// Apple's defaults first, so we'll use the first option that isn't our bundle
|
||||||
CFStringRef other = nil;
|
CFStringRef other = nil;
|
||||||
for (CFIndex i = 0; i < CFArrayGetCount(bundleList); i++) {
|
for (CFIndex i = 0; i < CFArrayGetCount(bundleList); i++) {
|
||||||
other = (CFStringRef)CFArrayGetValueAtIndex(bundleList, i);
|
other = base::mac::CFCast<CFStringRef>(CFArrayGetValueAtIndex(bundleList,
|
||||||
|
i));
|
||||||
if (![identifier isEqualToString: (__bridge NSString *)other]) {
|
if (![identifier isEqualToString: (__bridge NSString *)other]) {
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
|
@ -474,7 +474,7 @@ static NSString* const ImageScrubberItemIdentifier = @"scrubber.image.item";
|
||||||
settings.Get("segments", &segments);
|
settings.Get("segments", &segments);
|
||||||
|
|
||||||
control.segmentCount = segments.size();
|
control.segmentCount = segments.size();
|
||||||
for (int i = 0; i < (int)segments.size(); i++) {
|
for (size_t i = 0; i < segments.size(); i++) {
|
||||||
std::string label;
|
std::string label;
|
||||||
gfx::Image image;
|
gfx::Image image;
|
||||||
bool enabled = true;
|
bool enabled = true;
|
||||||
|
@ -581,7 +581,7 @@ static NSString* const ImageScrubberItemIdentifier = @"scrubber.image.item";
|
||||||
std::vector<mate::PersistentDictionary> items;
|
std::vector<mate::PersistentDictionary> items;
|
||||||
if (!settings.Get("items", &items)) return nil;
|
if (!settings.Get("items", &items)) return nil;
|
||||||
|
|
||||||
if (index >= (long)items.size()) return nil;
|
if (index >= static_cast<NSInteger>(items.size())) return nil;
|
||||||
|
|
||||||
mate::PersistentDictionary item = items[index];
|
mate::PersistentDictionary item = items[index];
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue