DataType DataName,
std::string locale,
autofill::AutofillProfile &ret) {
- std::u16string value;
static std::map<DataType, autofill::ServerFieldType> profile_map =
create_EWK_to_Autofill_profile_map();
+ if (profile_map.find(DataName) == profile_map.end()) {
+ return;
+ }
+ std::u16string value;
if (0 < (value = oldStyleProfile->get16Data(DataName)).length()) {
if (DataName == PROFILE_NAME || DataName == PROFILE_COUNTRY) {
ret.SetInfo(autofill::AutofillType(profile_map.find(DataName)->second),
value, locale);
- } else
+ } else if (profile_map.find(DataName) != profile_map.end())
ret.SetRawInfo(profile_map.find(DataName)->second, value);
}
}
value = newStyleProfile.GetRawInfo(DataName);
}
- if (value.length())
+ if (value.length() && (profile_map.find(DataName) != profile_map.end()))
ret->setData(profile_map.find(DataName)->second, base::UTF16ToASCII(value));
}
void __notification_cancel_cb(uint64_t notification_id, void* event_info)
{
evas_object_del(popup);
- printf("APP.C callback __notification_cancel_cb with notification id = %Lu\n", (long long unsigned int)notification_id);
+ printf("APP.C callback __notification_cancel_cb with notification id = %llu\n", notification_id);
}
void __policy_response_decide_cb(void *data, Evas_Object *obj, void *event_info)
}
static char snapshot_filename[256];
static int snapshot_count = 1;
- sprintf(snapshot_filename, "snapshot_img%04d.%s", snapshot_count++, "png");
+ snprintf(snapshot_filename, sizeof(snapshot_filename), "snapshot_img%04d.%s", snapshot_count++, "png");
if (evas_object_image_save(snapshot, snapshot_filename, 0, 0))
printf("Snapshot image saved in %s\n", snapshot_filename);
else
evas_object_image_data_copy_set(image, ewk_hit_test_image_buffer_get(ht));
static char filename_buffer[256];
static int count = 1;
- sprintf(filename_buffer, "hit_test_img%04d.%s", count++, ewk_hit_test_image_file_name_extension_get(ht));
+ snprintf(filename_buffer, sizeof(filename_buffer), "hit_test_img%04d.%s", count++, ewk_hit_test_image_file_name_extension_get(ht));
if (evas_object_image_save(image, filename_buffer, 0, 0))
printf("Hit test image saved in %s\n", filename_buffer);
else
log_info("UI type: %s", desktop_ ? "desktop" : "mobile");
if (IsDesktopProfile()) {
- log_info("Runtime Profile : DESKTOP : ", IsDesktopProfile());
+ log_info("Runtime Profile : DESKTOP");
} else if (IsMobileProfile()) {
- log_info("Runtime Profile : MOBILE : ", IsMobileProfile());
+ log_info("Runtime Profile : MOBILE");
} else if (IsTvProfile()) {
- log_info("Runtime Profile : TV : ", IsTvProfile());
+ log_info("Runtime Profile : TV");
} else if (IsWearableProfile()) {
- log_info("Runtime Profile : WEARABLE : ", IsWearableProfile());
+ log_info("Runtime Profile : WEARABLE");
} else if (IsIviProfile()) {
- log_info("Runtime Profile : IVI : ", IsIviProfile());
+ log_info("Runtime Profile : IVI");
} else if (IsCommonProfile()) {
- log_info("Runtime Profile : COMMON : ", IsCommonProfile());
+ log_info("Runtime Profile : COMMON");
} else {
- log_info("Runtime Profile : UNKNOWN : ");
+ log_info("Runtime Profile : UNKNOWN");
}
if (IsEmulatorArch()) {
- log_info("Runtime Architecture : EMULATOR : ", IsEmulatorArch());
+ log_info("Runtime Architecture : EMULATOR");
}
// If we don't call ewk_context_default_get here, ubrowser crashes in desktop
if (window_list_)
elm_list_go(window_list_);
- log_trace("%s: %x", __PRETTY_FUNCTION__, data.window->Id());
+ log_trace("%s: %p", __PRETTY_FUNCTION__, data.window->Id());
return *data.window;
}
}
void Browser::StartVibration(uint64_t duration) {
- log_trace("%s: %d", __PRETTY_FUNCTION__, duration);
+ log_trace("%s: %llu", __PRETTY_FUNCTION__, duration);
#if BUILDFLAG(IS_TIZEN)
if (IsMobileProfile() || IsWearableProfile()) {
if (haptic_timer_id_) {
}
void Browser::OnWindowDestroyed(Window::IdType id) {
- log_trace("%s: %x", __PRETTY_FUNCTION__, id);
+ log_trace("%s: %p", __PRETTY_FUNCTION__, id);
assert(window_map_.find(id) != window_map_.end());
WindowMapData window_map_data = window_map_[id];
if (window_map_data.list_elm)