And use it for newly created instances.
Change-Id: I1e34423bbc8017023a022513f076e954070b28a2
extern int client_broadcast(struct inst_info *inst, struct packet *packet);
extern const char *client_direct_addr(const struct client_node *client);
+
+extern int client_orientation(const struct client_node *client);
+extern void client_set_orientation(struct client_node *client, int orientation);
/* End of a file */
int faulted;
char *direct_addr;
+ int orientation;
};
static inline void invoke_global_destroyed_cb(struct client_node *client)
return client ? client->direct_addr : NULL;
}
+HAPI void client_set_orientation(struct client_node *client, int orientation)
+{
+ client->orientation = orientation;
+}
+
+HAPI int client_orientation(const struct client_node *client)
+{
+ return client->orientation;
+}
+
/* End of a file */
if (client_event_callback_add(inst->client, CLIENT_EVENT_DEACTIVATE, client_deactivated_cb, inst) < 0) {
ErrPrint("Failed to add client event callback: %s\n", inst->id);
}
+ inst->orientation = client_orientation(client);
}
if (fork_package(inst, pkgname) < 0) {
return NULL;
}
-static struct packet *client_orientation(pid_t pid, int handle, const struct packet *packet)
+static struct packet *client_change_orientation(pid_t pid, int handle, const struct packet *packet)
{
struct client_node *client;
double timestamp;
ret = 0;
+ client_set_orientation(client, degree);
+
pkg_list = (Eina_List *)package_list();
EINA_LIST_FOREACH(pkg_list, l, pkg) {
}
}
DbgPrint("%d instances are affected (orientation: %d)\n", ret, degree);
-
out:
return NULL;
}
},
{
.cmd = CMD_STR_ORIENTATION,
- .handler = client_orientation,
+ .handler = client_change_orientation,
},
{
.cmd = CMD_STR_CHANGE_VISIBILITY,