char trace_env_path[PATH_MAX + 1];
static FILE *log_fp_ptrace = NULL;
static struct wl_protocol_logger *ds_wl_protocol_logger;
-static struct protocol_trace_rule_checker *rc = NULL;
+static struct protocol_trace_rule_checker *global_rc = NULL;
static struct wl_display *display;
static struct
const char *cmd = "";
int ret;
- if (!rc)
+ if (!global_rc)
return false;
cmd = logger_cmd_get(log->cmd);
- ret = rulechecker_validate_rules(rc, log->type, log->target_id, log->name,
+ ret = rulechecker_validate_rules(global_rc, log->type, log->target_id, log->name,
log->client_pid, cmd);
return ret;
ds_dbg("(parameter) argc = %d, argv[0] = %s", argc, argv[0]);
if (argc == 0) {
- rulechecker_print_rules(rc, reply, len);
+ rulechecker_print_rules(global_rc, reply, len);
return true;
}
if (apply == 0) {
const char * plus = "|| type=reply || type=error";
int size_plus = strlen(plus);
- int len = MIN(size_rule - index, size_plus);
+ int l = MIN(size_rule - index, size_plus);
snprintf(rule, sizeof(rule), "%s", plus);
- index += len;
+ index += l;
if (index >size_rule)
return false;
apply =1;
}
ds_dbg("ADD :: rule = %s", rule);
- result = rulechecker_rule_add(rc, policy_type, rule);
+ result = rulechecker_rule_add(global_rc, policy_type, rule);
if (result == PROTOCOL_TRACE_RULE_SET_ERR_TOO_MANY_RULES) {
ds_err("Error: Too many rules were added.");
remove_idx = argv[i + 1];
if (!strcasecmp(remove_idx, "all")) {
ds_dbg("REMOVE :: all");
- rulechecker_destroy(rc);
- rc = rulechecker_init();
- if (!rc) {
+ rulechecker_destroy(global_rc);
+ global_rc = rulechecker_init();
+ if (!global_rc) {
ds_err("Error: rules not removed");
return false;
}
ds_dbg("REMOVE :: remove idx = %d", index);
if (isdigit(*remove_idx) &&
- rulechecker_rule_remove(rc, index) == 0)
+ rulechecker_rule_remove(global_rc, index) == 0)
ds_dbg("Rule remove success : rule [%d]", index);
else
ds_err("Rule remove fail : No rule [%s]", remove_idx);
if (!rule_file_set(argv[1], reply, len))
return false;
- rulechecker_print_rules(rc, reply, len);
+ rulechecker_print_rules(global_rc, reply, len);
} else if (!strcasecmp(command, "print")) {
- rulechecker_print_rules(rc, reply, len);
+ rulechecker_print_rules(global_rc, reply, len);
} else if (!strcasecmp(command, "help")) {
ds_dbg( "%s", rulechecker_usage_print());
} else {
char *env_path = NULL;
display = d;
- rc = rulechecker_init();
+ global_rc = rulechecker_init();
env_path = getenv("DS_PROTOCOL_RULE_FILE");
ret = rule_init(env_path);
void
protocol_trace_fini()
{
- rulechecker_destroy(rc);
-}
\ No newline at end of file
+ rulechecker_destroy(global_rc);
+}
ds_inf("Launch effect. type_set: pid(%u) type:%s", event->pid, (event->effect_type == 1) ? "depth-in" : "launch");
wl_list_for_each(view, &launch->server->views, link) {
- if (view->pid == event->pid) {
+ if ((uint32_t)view->pid == event->pid) {
view->effect_type = event->effect_type;
existing = true;
ds_inf("Launch effect. existing pid");
ds_inf("Launch effect. type_unset: pid(%u)", event->pid);
wl_list_for_each(view, &launch->server->views, link) {
- if (view->pid == event->pid) {
+ if ((uint32_t)view->pid == event->pid) {
view->effect_type = -1;
ds_inf("Launch effect. pid found");
}
ds_inf("Splash owner. pid(%u)", event->pid);
wl_list_for_each(view, &launch->server->views, link) {
- if (view->pid == event->pid) {
+ if ((uint32_t)view->pid == event->pid) {
if (event->pid == ds_tizen_launch_splash_get_pid(launch->splash))
;//
else {
struct ds_tdm_output_hwc_window **changed_hwc_windows = NULL;
enum ds_tdm_output_hwc_window_composition composition;
struct tinyds_view *view;
- int i;
+ size_t i;
bool need_target = false;
bool fully_obscured = false;
struct ds_buffer *ds_buffer;
return;
}
- for (i = 0; i < num_changed; i++) {
+ for (i = 0; i < (size_t)num_changed; i++) {
composition = ds_tdm_output_hwc_window_get_composition(changed_hwc_windows[i]);
if (composition == DS_TDM_OUTPUT_HWC_WINDOW_COMPOSITION_CLIENT) {
need_target = true;
output->target_updated = false;
wl_list_for_each(view, &output->server->views, link) {
- enum ds_tdm_output_hwc_window_composition composition;
-
if (!view->mapped)
continue;
]
)
+cc = meson.get_compiler('c')
+
+add_project_arguments(cc.get_supported_arguments([
+ '-Wno-missing-field-initializers',
+ '-Wno-unused-parameter',
+ '-Wno-pedantic',
+ '-Wno-missing-braces',
+]), language: ['c', 'cpp'])
+
libds_tizen_version = meson.project_version()
version_arr = libds_tizen_version.split('.')
libds_tizen_version_major = version_arr[0]
tdm_error terr;
tdm_hwc_window **compositied_hwc_windows = NULL;
struct ds_tdm_output_hwc_window *hwc_window;
- int i;
+ size_t i;
wl_list_for_each(hwc_window, &hwc->hwc_windows, link)
hwc_window_update(hwc_window);
if (!compositied_hwc_windows)
return false;
- for (i = 0; i < num_windows; i++)
+ for (i = 0; i < (size_t)num_windows; i++)
compositied_hwc_windows[i] = composited_windows[i]->twindow;
}
tdm_hwc_window_composition *compositions = NULL;
struct ds_tdm_output_hwc_window *hwc_window;
tdm_error terr;
- int i;
+ size_t i;
if (!hwc->validate_num_changed) {
*num_changed = 0;
return false;
}
- for (i = 0; i < hwc->validate_num_changed; i++) {
- if (i >= *num_changed)
+ for (i = 0; i < (size_t)hwc->validate_num_changed; i++) {
+ if (i >= (size_t)*num_changed)
break;
hwc_window = hwc_get_hwc_window_from_tdm_hwc_window(hwc, changed_thwc_windows[i]);
struct ds_tizen_eom_output *output;
wl_list_for_each(output, &eom->outputs, link) {
- if (output->id == id)
+ if ((uint32_t)output->id == id)
return output;
}
{
struct ds_surface *surface;
- int32_t state;
- int32_t opacity_mode;
- int32_t visible_type;
+ enum ds_tizen_indicator_state state;
+ enum ds_tizen_indicator_opacity_mode opacity_mode;
+ enum ds_tizen_indicator_visible_type visible_type;
struct wl_list link; // ds_tizen_indicator_client::infos
};
// enum ds_tizen_indicator_opacity_mode and
// enum ds_tizen_indicator_opacity_mode
// because of the first signal emit for change_state signal.
- info->state = -1;
- info->opacity_mode = -1;
- info->visible_type = -1;
+ info->state = DS_TIZEN_INDICATOR_STATE_UNKNOWN;
+ info->opacity_mode = DS_TIZEN_INDICATOR_OPACITY_MODE_UNKNOWN;
+ info->visible_type = DS_TIZEN_INDICATOR_VISIBLE_TYPE_HIDDEN;
wl_list_insert(&client->infos, &info->link);
goto finish;
}
- if (finger >= tz_devicemgr->touch_max_count)
+ if (finger >= (uint32_t)tz_devicemgr->touch_max_count)
{
ds_err("Invalid fingers: %d\n", finger);
ret = TIZEN_INPUT_DEVICE_MANAGER_ERROR_INVALID_PARAMETER;
return;
}
- if (info->pid != pid)
+ if ((uint32_t)info->pid != pid)
appinfo_set_pid(info, pid);
wl_signal_emit(&client->appinfo_mgr->events.metadata_ready, info);
policy = client->policy;
wl_list_for_each(client, &policy->clients, link) {
- if (pid == client->pid) {
+ if (pid == (uint32_t)client->pid) {
struct ds_tizen_policy_event_set_background_state event = {
.policy = client->policy,
.pid = pid,
policy = client->policy;
wl_list_for_each(client, &policy->clients, link) {
- if (pid == client->pid) {
+ if (pid == (uint32_t)client->pid) {
struct ds_tizen_policy_event_unset_background_state event = {
.policy = client->policy,
.pid = pid,
static const struct tizen_policy_interface policy_impl =
{
- policy_handle_get_visibility,
- policy_handle_get_position,
- policy_handle_activate,
- policy_handle_activate_below_by_res_id,
- policy_handle_raise,
- policy_handle_lower,
- policy_handle_lower_by_res_id,
- policy_handle_set_focus_skip,
- policy_handle_unset_focus_skip,
- policy_handle_set_role,
- policy_handle_set_type,
- policy_handle_set_conformant,
- policy_handle_unset_conformant,
- policy_handle_get_conformant,
- policy_handle_set_notification_level,
- policy_handle_set_transient_for,
- policy_handle_unset_transient_for,
- policy_handle_set_window_screen_mode,
- policy_handle_place_subsurface_below_parent,
- policy_handle_set_subsurface_stand_alone,
- policy_handle_get_subsurface,
- policy_handle_set_opaque_state,
- policy_handle_iconify,
- policy_handle_uniconify,
- policy_handle_add_aux_hint,
- policy_handle_change_aux_hint,
- policy_handle_delete_aux_hint,
- policy_handle_get_supported_aux_hints,
- policy_handle_set_background_state,
- policy_handle_unset_background_state,
- policy_handle_set_floating_mode,
- policy_handle_unset_floating_mode,
- policy_handle_set_stack_mode,
- policy_handle_activate_above_by_res_id,
- policy_handle_get_subsurface_watcher,
- policy_handle_set_parent,
- policy_handle_ack_conformant_region,
- policy_handle_destroy,
- policy_handle_has_video,
- policy_handle_set_appid,
- policy_handle_show,
- policy_handle_hide,
- policy_handle_set_transient_for_below,
- policy_handle_set_parent_with_below,
+ .get_visibility = policy_handle_get_visibility,
+ .get_position = policy_handle_get_position,
+ .activate = policy_handle_activate,
+ .activate_below_by_res_id = policy_handle_activate_below_by_res_id,
+ .raise = policy_handle_raise,
+ .lower = policy_handle_lower,
+ .lower_by_res_id = policy_handle_lower_by_res_id,
+ .set_focus_skip = policy_handle_set_focus_skip,
+ .unset_focus_skip = policy_handle_unset_focus_skip,
+ .set_role = policy_handle_set_role,
+ .set_type = policy_handle_set_type,
+ .set_conformant = policy_handle_set_conformant,
+ .unset_conformant = policy_handle_unset_conformant,
+ .get_conformant = policy_handle_get_conformant,
+ .set_notification_level = policy_handle_set_notification_level,
+ .set_transient_for = policy_handle_set_transient_for,
+ .unset_transient_for = policy_handle_unset_transient_for,
+ .set_window_screen_mode = policy_handle_set_window_screen_mode,
+ .place_subsurface_below_parent = policy_handle_place_subsurface_below_parent,
+ .set_subsurface_stand_alone = policy_handle_set_subsurface_stand_alone,
+ .get_subsurface = policy_handle_get_subsurface,
+ .set_opaque_state = policy_handle_set_opaque_state,
+ .iconify = policy_handle_iconify,
+ .uniconify = policy_handle_uniconify,
+ .add_aux_hint = policy_handle_add_aux_hint,
+ .change_aux_hint = policy_handle_change_aux_hint,
+ .del_aux_hint = policy_handle_delete_aux_hint,
+ .get_supported_aux_hints = policy_handle_get_supported_aux_hints,
+ .set_background_state = policy_handle_set_background_state,
+ .unset_background_state = policy_handle_unset_background_state,
+ .set_floating_mode = policy_handle_set_floating_mode,
+ .unset_floating_mode = policy_handle_unset_floating_mode,
+ .set_stack_mode = policy_handle_set_stack_mode,
+ .activate_above_by_res_id = policy_handle_activate_above_by_res_id,
+ .get_subsurface_watcher = policy_handle_get_subsurface_watcher,
+ .set_parent = policy_handle_set_parent,
+ .ack_conformant_region = policy_handle_ack_conformant_region,
+ .destroy = policy_handle_destroy,
+ .has_video = policy_handle_has_video,
+ .set_appid = policy_handle_set_appid,
+ .show = policy_handle_show,
+ .hide = policy_handle_hide,
+ .set_transient_for_below = policy_handle_set_transient_for_below,
+ .set_parent_with_below = policy_handle_set_parent_with_below,
};
static void
#define TIZEN_REMOTE_SURFACE_VERSION 6
-static uint32_t resource_id = 1;
+static uint32_t global_resource_id = 1;
struct ds_tizen_remote_surface_manager
{
wl_signal_emit(&remote_client->remote_manager->events.new_provider, remote_provider);
- remote_provider->resource_id = resource_id++;
+ remote_provider->resource_id = global_resource_id++;
tizen_remote_surface_provider_send_resource_id(remote_provider->resource, remote_provider->resource_id);
{
};
-INSTANTIATE_TEST_SUITE_P(ScalerBadSourceParamTest,
+INSTANTIATE_TEST_CASE_P(ScalerBadSourceParamTest,
ScalerCompositorBadSourceTest,
testing::Values(
Box{0, 0, 0, 0},
{
};
-INSTANTIATE_TEST_SUITE_P(ScalerBadDestinationParamTest,
+INSTANTIATE_TEST_CASE_P(ScalerBadDestinationParamTest,
ScalerCompositorBadDestinationTest,
testing::Values(
Size{0, 0},