summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorFelipe Magno de Almeida <felipe@expertise.dev>2020-10-24 09:01:36 -0300
committerFelipe Magno de Almeida <felipe@expertise.dev>2020-12-14 13:22:33 -0300
commit21674baf68b2bb719a20d6827e69a1d56970308c (patch)
treed874f45f2824aafd02801c85a3a545c0717542f4
parent1dba2f717ac6671c121df6c021e0e1ea9f01b42c (diff)
ecore_win32: Rename EAPI macro to ECORE_WIN32_API in Ecore Win32 library
Patch from a series of patches to rename EAPI symbols to specific library DSOs. EAPI was designed to be able to pass ```__attribute__ ((visibility ("default")))``` for symbols with GCC, which would mean that even if -fvisibility=hidden was used when compiling the library, the needed symbols would get exported. MSVC __almost__ works like GCC (or mingw) in which you can declare everything as export and it will just work (slower, but it will work). But there's a caveat: global variables will not work the same way for MSVC, but works for mingw and GCC. For global variables (as opposed to functions), MSVC requires correct DSO visibility for MSVC: instead of declaring a symbol as export for everything, you need to declare it as import when importing from another DSO and export when defining it locally. With current EAPI definitions, we get the following example working in mingw and MSVC (observe it doesn't define any global variables as exported symbols). Example 1: dll1: ``` EAPI void foo(void); EAPI void bar() { foo(); } ``` dll2: ``` EAPI void foo() { printf ("foo\n"); } ``` This works fine with API defined as __declspec(dllexport) in both cases and for gcc defining as ```__atttribute__((visibility("default")))```. However, the following: Example 2: dll1: ``` EAPI extern int foo; EAPI void foobar(void); EAPI void bar() { foo = 5; foobar(); } ``` dll2: ``` EAPI int foo = 0; EAPI void foobar() { printf ("foo %d\n", foo); } ``` This will work on mingw but will not work for MSVC. And that's why EAPI is the only solution that worked for MSVC. Co-authored-by: João Paulo Taylor Ienczak Zanette <jpaulotiz@gmail.com> Co-authored-by: Ricardo Campos <ricardo.campos@expertise.dev> Co-authored-by: Lucas Cavalcante de Sousa <lucks.sousa@gmail.com>
-rw-r--r--src/lib/ecore_win32/Ecore_Win32.h166
-rw-r--r--src/lib/ecore_win32/ecore_win32.c12
-rw-r--r--src/lib/ecore_win32/ecore_win32_api.h34
-rw-r--r--src/lib/ecore_win32/ecore_win32_clipboard.c6
-rw-r--r--src/lib/ecore_win32/ecore_win32_cursor.c12
-rw-r--r--src/lib/ecore_win32/ecore_win32_dnd.c10
-rw-r--r--src/lib/ecore_win32/ecore_win32_monitor.c2
-rw-r--r--src/lib/ecore_win32/ecore_win32_window.c64
-rw-r--r--src/lib/ecore_win32/meson.build2
9 files changed, 157 insertions, 151 deletions
diff --git a/src/lib/ecore_win32/Ecore_Win32.h b/src/lib/ecore_win32/Ecore_Win32.h
index b83f8dae54..78b8d6ac07 100644
--- a/src/lib/ecore_win32/Ecore_Win32.h
+++ b/src/lib/ecore_win32/Ecore_Win32.h
@@ -20,32 +20,7 @@
20 20
21#include <Eina.h> 21#include <Eina.h>
22 22
23#ifdef EAPI 23#include <ecore_win32_api.h>
24# undef EAPI
25#endif
26
27#ifdef _WIN32
28# ifdef EFL_BUILD
29# ifdef DLL_EXPORT
30# define EAPI __declspec(dllexport)
31# else
32# define EAPI
33# endif
34# else
35# define EAPI __declspec(dllimport)
36# endif
37#else
38# ifdef __GNUC__
39# if __GNUC__ >= 4
40# define EAPI __attribute__ ((visibility("default")))
41# else
42# define EAPI
43# endif
44# else
45# define EAPI
46# endif
47#endif
48
49 24
50#ifdef __cplusplus 25#ifdef __cplusplus
51extern "C" { 26extern "C" {
@@ -504,176 +479,176 @@ struct _Ecore_Win32_Event_Selection_Notify
504 */ 479 */
505typedef int (*Ecore_Win32_Dnd_DropTarget_Callback)(void *window, int event, int pt_x, int pt_y, void *data, int size); 480typedef int (*Ecore_Win32_Dnd_DropTarget_Callback)(void *window, int event, int pt_x, int pt_y, void *data, int size);
506 481
507EAPI extern int ECORE_WIN32_EVENT_MOUSE_IN; /**< Ecore_Event for the #Ecore_Win32_Event_Mouse_In event */ 482ECORE_WIN32_API extern int ECORE_WIN32_EVENT_MOUSE_IN; /**< Ecore_Event for the #Ecore_Win32_Event_Mouse_In event */
508EAPI extern int ECORE_WIN32_EVENT_MOUSE_OUT; /**< Ecore_Event for the #Ecore_Win32_Event_Mouse_Out event */ 483ECORE_WIN32_API extern int ECORE_WIN32_EVENT_MOUSE_OUT; /**< Ecore_Event for the #Ecore_Win32_Event_Mouse_Out event */
509EAPI extern int ECORE_WIN32_EVENT_WINDOW_FOCUS_IN; /**< Ecore_Event for the #Ecore_Win32_Event_Window_Focus_In event */ 484ECORE_WIN32_API extern int ECORE_WIN32_EVENT_WINDOW_FOCUS_IN; /**< Ecore_Event for the #Ecore_Win32_Event_Window_Focus_In event */
510EAPI extern int ECORE_WIN32_EVENT_WINDOW_FOCUS_OUT; /**< Ecore_Event for the #Ecore_Win32_Event_Window_Focus_Out event */ 485ECORE_WIN32_API extern int ECORE_WIN32_EVENT_WINDOW_FOCUS_OUT; /**< Ecore_Event for the #Ecore_Win32_Event_Window_Focus_Out event */
511EAPI extern int ECORE_WIN32_EVENT_WINDOW_DAMAGE; /**< Ecore_Event for the Ecore_Win32_Event_Damage event */ 486ECORE_WIN32_API extern int ECORE_WIN32_EVENT_WINDOW_DAMAGE; /**< Ecore_Event for the Ecore_Win32_Event_Damage event */
512EAPI extern int ECORE_WIN32_EVENT_WINDOW_CREATE; /**< Ecore_Event for the Ecore_Win32_Event_Create event */ 487ECORE_WIN32_API extern int ECORE_WIN32_EVENT_WINDOW_CREATE; /**< Ecore_Event for the Ecore_Win32_Event_Create event */
513EAPI extern int ECORE_WIN32_EVENT_WINDOW_DESTROY; /**< Ecore_Event for the Ecore_Win32_Event_Destroy event */ 488ECORE_WIN32_API extern int ECORE_WIN32_EVENT_WINDOW_DESTROY; /**< Ecore_Event for the Ecore_Win32_Event_Destroy event */
514EAPI extern int ECORE_WIN32_EVENT_WINDOW_HIDE; /**< Ecore_Event for the Ecore_Win32_Event_Hide event */ 489ECORE_WIN32_API extern int ECORE_WIN32_EVENT_WINDOW_HIDE; /**< Ecore_Event for the Ecore_Win32_Event_Hide event */
515EAPI extern int ECORE_WIN32_EVENT_WINDOW_SHOW; /**< Ecore_Event for the Ecore_Win32_Event_Show event */ 490ECORE_WIN32_API extern int ECORE_WIN32_EVENT_WINDOW_SHOW; /**< Ecore_Event for the Ecore_Win32_Event_Show event */
516EAPI extern int ECORE_WIN32_EVENT_WINDOW_CONFIGURE; /**< Ecore_Event for the Ecore_Win32_Event_Configure event */ 491ECORE_WIN32_API extern int ECORE_WIN32_EVENT_WINDOW_CONFIGURE; /**< Ecore_Event for the Ecore_Win32_Event_Configure event */
517EAPI extern int ECORE_WIN32_EVENT_WINDOW_RESIZE; /**< Ecore_Event for the Ecore_Win32_Event_Resize event */ 492ECORE_WIN32_API extern int ECORE_WIN32_EVENT_WINDOW_RESIZE; /**< Ecore_Event for the Ecore_Win32_Event_Resize event */
518EAPI extern int ECORE_WIN32_EVENT_WINDOW_PROPERTY; /**< Ecore_Event for the Ecore_Win32_Event_Property event @since 1.20 */ 493ECORE_WIN32_API extern int ECORE_WIN32_EVENT_WINDOW_PROPERTY; /**< Ecore_Event for the Ecore_Win32_Event_Property event @since 1.20 */
519EAPI extern int ECORE_WIN32_EVENT_WINDOW_DELETE_REQUEST; /**< Ecore_Event for the #Ecore_Win32_Event_Window_Delete_Request event */ 494ECORE_WIN32_API extern int ECORE_WIN32_EVENT_WINDOW_DELETE_REQUEST; /**< Ecore_Event for the #Ecore_Win32_Event_Window_Delete_Request event */
520EAPI extern int ECORE_WIN32_EVENT_SELECTION_CLEAR; /**< Ecore_Event for the #Ecore_Win32_Event_Selection_Clear event @since 1.16 */ 495ECORE_WIN32_API extern int ECORE_WIN32_EVENT_SELECTION_CLEAR; /**< Ecore_Event for the #Ecore_Win32_Event_Selection_Clear event @since 1.16 */
521EAPI extern int ECORE_WIN32_EVENT_SELECTION_NOTIFY; /**< Ecore_Event for the #Ecore_Win32_Event_Selection_Notify event @since 1.16 */ 496ECORE_WIN32_API extern int ECORE_WIN32_EVENT_SELECTION_NOTIFY; /**< Ecore_Event for the #Ecore_Win32_Event_Selection_Notify event @since 1.16 */
522 497
523 498
524/* Core */ 499/* Core */
525 500
526EAPI int ecore_win32_init(); 501ECORE_WIN32_API int ecore_win32_init();
527EAPI int ecore_win32_shutdown(); 502ECORE_WIN32_API int ecore_win32_shutdown();
528EAPI int ecore_win32_screen_depth_get(); 503ECORE_WIN32_API int ecore_win32_screen_depth_get();
529EAPI void ecore_win32_double_click_time_set(double t); 504ECORE_WIN32_API void ecore_win32_double_click_time_set(double t);
530EAPI double ecore_win32_double_click_time_get(void); 505ECORE_WIN32_API double ecore_win32_double_click_time_get(void);
531EAPI unsigned long ecore_win32_current_time_get(void); 506ECORE_WIN32_API unsigned long ecore_win32_current_time_get(void);
532 507
533/* Window */ 508/* Window */
534 509
535EAPI Ecore_Win32_Window *ecore_win32_window_new(Ecore_Win32_Window *parent, 510ECORE_WIN32_API Ecore_Win32_Window *ecore_win32_window_new(Ecore_Win32_Window *parent,
536 int x, 511 int x,
537 int y, 512 int y,
538 int width, 513 int width,
539 int height); 514 int height);
540EAPI Ecore_Win32_Window *ecore_win32_window_override_new(Ecore_Win32_Window *parent, 515ECORE_WIN32_API Ecore_Win32_Window *ecore_win32_window_override_new(Ecore_Win32_Window *parent,
541 int x, 516 int x,
542 int y, 517 int y,
543 int width, 518 int width,
544 int height); 519 int height);
545 520
546EAPI void ecore_win32_window_free(Ecore_Win32_Window *window); 521ECORE_WIN32_API void ecore_win32_window_free(Ecore_Win32_Window *window);
547 522
548EAPI void *ecore_win32_window_hwnd_get(Ecore_Win32_Window *window); 523ECORE_WIN32_API void *ecore_win32_window_hwnd_get(Ecore_Win32_Window *window);
549 524
550EAPI void ecore_win32_window_move(Ecore_Win32_Window *window, 525ECORE_WIN32_API void ecore_win32_window_move(Ecore_Win32_Window *window,
551 int x, 526 int x,
552 int y); 527 int y);
553 528
554EAPI void ecore_win32_window_resize(Ecore_Win32_Window *window, 529ECORE_WIN32_API void ecore_win32_window_resize(Ecore_Win32_Window *window,
555 int width, 530 int width,
556 int height); 531 int height);
557 532
558EAPI void ecore_win32_window_move_resize(Ecore_Win32_Window *window, 533ECORE_WIN32_API void ecore_win32_window_move_resize(Ecore_Win32_Window *window,
559 int x, 534 int x,
560 int y, 535 int y,
561 int width, 536 int width,
562 int height); 537 int height);
563 538
564EAPI void ecore_win32_window_geometry_get(Ecore_Win32_Window *window, 539ECORE_WIN32_API void ecore_win32_window_geometry_get(Ecore_Win32_Window *window,
565 int *x, 540 int *x,
566 int *y, 541 int *y,
567 int *width, 542 int *width,
568 int *height); 543 int *height);
569 544
570EAPI void ecore_win32_window_size_get(Ecore_Win32_Window *window, 545ECORE_WIN32_API void ecore_win32_window_size_get(Ecore_Win32_Window *window,
571 int *width, 546 int *width,
572 int *height); 547 int *height);
573 548
574EAPI void ecore_win32_window_size_min_set(Ecore_Win32_Window *window, 549ECORE_WIN32_API void ecore_win32_window_size_min_set(Ecore_Win32_Window *window,
575 int min_width, 550 int min_width,
576 int min_height); 551 int min_height);
577 552
578EAPI void ecore_win32_window_size_min_get(Ecore_Win32_Window *window, 553ECORE_WIN32_API void ecore_win32_window_size_min_get(Ecore_Win32_Window *window,
579 int *min_width, 554 int *min_width,
580 int *min_height); 555 int *min_height);
581 556
582EAPI void ecore_win32_window_size_max_set(Ecore_Win32_Window *window, 557ECORE_WIN32_API void ecore_win32_window_size_max_set(Ecore_Win32_Window *window,
583 int max_width, 558 int max_width,
584 int max_height); 559 int max_height);
585 560
586EAPI void ecore_win32_window_size_max_get(Ecore_Win32_Window *window, 561ECORE_WIN32_API void ecore_win32_window_size_max_get(Ecore_Win32_Window *window,
587 int *max_width, 562 int *max_width,
588 int *max_height); 563 int *max_height);
589 564
590EAPI void ecore_win32_window_size_base_set(Ecore_Win32_Window *window, 565ECORE_WIN32_API void ecore_win32_window_size_base_set(Ecore_Win32_Window *window,
591 int base_width, 566 int base_width,
592 int base_height); 567 int base_height);
593 568
594EAPI void ecore_win32_window_size_base_get(Ecore_Win32_Window *window, 569ECORE_WIN32_API void ecore_win32_window_size_base_get(Ecore_Win32_Window *window,
595 int *base_width, 570 int *base_width,
596 int *base_height); 571 int *base_height);
597 572
598EAPI void ecore_win32_window_size_step_set(Ecore_Win32_Window *window, 573ECORE_WIN32_API void ecore_win32_window_size_step_set(Ecore_Win32_Window *window,
599 int step_width, 574 int step_width,
600 int step_height); 575 int step_height);
601 576
602EAPI void ecore_win32_window_size_step_get(Ecore_Win32_Window *window, 577ECORE_WIN32_API void ecore_win32_window_size_step_get(Ecore_Win32_Window *window,
603 int *step_width, 578 int *step_width,
604 int *step_height); 579 int *step_height);
605 580
606EAPI void ecore_win32_window_show(Ecore_Win32_Window *window); 581ECORE_WIN32_API void ecore_win32_window_show(Ecore_Win32_Window *window);
607 582
608EAPI void ecore_win32_window_hide(Ecore_Win32_Window *window); 583ECORE_WIN32_API void ecore_win32_window_hide(Ecore_Win32_Window *window);
609 584
610EAPI void ecore_win32_window_raise(Ecore_Win32_Window *window); 585ECORE_WIN32_API void ecore_win32_window_raise(Ecore_Win32_Window *window);
611 586
612EAPI void ecore_win32_window_lower(Ecore_Win32_Window *window); 587ECORE_WIN32_API void ecore_win32_window_lower(Ecore_Win32_Window *window);
613 588
614EAPI void ecore_win32_window_title_set(Ecore_Win32_Window *window, 589ECORE_WIN32_API void ecore_win32_window_title_set(Ecore_Win32_Window *window,
615 const char *title); 590 const char *title);
616 591
617EAPI void ecore_win32_window_focus(Ecore_Win32_Window *window); 592ECORE_WIN32_API void ecore_win32_window_focus(Ecore_Win32_Window *window);
618 593
619EAPI void *ecore_win32_window_focus_get(void); 594ECORE_WIN32_API void *ecore_win32_window_focus_get(void);
620 595
621EAPI void ecore_win32_window_iconified_set(Ecore_Win32_Window *window, 596ECORE_WIN32_API void ecore_win32_window_iconified_set(Ecore_Win32_Window *window,
622 Eina_Bool on); 597 Eina_Bool on);
623 598
624EAPI void ecore_win32_window_borderless_set(Ecore_Win32_Window *window, 599ECORE_WIN32_API void ecore_win32_window_borderless_set(Ecore_Win32_Window *window,
625 Eina_Bool on); 600 Eina_Bool on);
626 601
627EAPI void ecore_win32_window_fullscreen_set(Ecore_Win32_Window *window, 602ECORE_WIN32_API void ecore_win32_window_fullscreen_set(Ecore_Win32_Window *window,
628 Eina_Bool on); 603 Eina_Bool on);
629 604
630EAPI void ecore_win32_window_cursor_set(Ecore_Win32_Window *window, 605ECORE_WIN32_API void ecore_win32_window_cursor_set(Ecore_Win32_Window *window,
631 Ecore_Win32_Cursor *cursor); 606 Ecore_Win32_Cursor *cursor);
632 607
633EAPI void ecore_win32_window_state_set(Ecore_Win32_Window *window, 608ECORE_WIN32_API void ecore_win32_window_state_set(Ecore_Win32_Window *window,
634 Ecore_Win32_Window_State *state, 609 Ecore_Win32_Window_State *state,
635 unsigned int num); 610 unsigned int num);
636 611
637EAPI void ecore_win32_window_state_get(Ecore_Win32_Window *window, 612ECORE_WIN32_API void ecore_win32_window_state_get(Ecore_Win32_Window *window,
638 Ecore_Win32_Window_State **state, 613 Ecore_Win32_Window_State **state,
639 unsigned int *num); 614 unsigned int *num);
640 615
641EAPI void ecore_win32_window_state_request_send(Ecore_Win32_Window *window, 616ECORE_WIN32_API void ecore_win32_window_state_request_send(Ecore_Win32_Window *window,
642 Ecore_Win32_Window_State state, 617 Ecore_Win32_Window_State state,
643 unsigned int set); 618 unsigned int set);
644 619
645EAPI void ecore_win32_window_type_set(Ecore_Win32_Window *window, 620ECORE_WIN32_API void ecore_win32_window_type_set(Ecore_Win32_Window *window,
646 Ecore_Win32_Window_Type type); 621 Ecore_Win32_Window_Type type);
647 622
648/* Cursor */ 623/* Cursor */
649 624
650EAPI Ecore_Win32_Cursor *ecore_win32_cursor_new(const void *pixels_and, 625ECORE_WIN32_API Ecore_Win32_Cursor *ecore_win32_cursor_new(const void *pixels_and,
651 const void *pixels_xor, 626 const void *pixels_xor,
652 int width, 627 int width,
653 int height, 628 int height,
654 int hot_x, 629 int hot_x,
655 int hot_y); 630 int hot_y);
656 631
657EAPI void ecore_win32_cursor_free(Ecore_Win32_Cursor *cursor); 632ECORE_WIN32_API void ecore_win32_cursor_free(Ecore_Win32_Cursor *cursor);
658 633
659EAPI Ecore_Win32_Cursor *ecore_win32_cursor_shaped_new(Ecore_Win32_Cursor_Shape shape); 634ECORE_WIN32_API Ecore_Win32_Cursor *ecore_win32_cursor_shaped_new(Ecore_Win32_Cursor_Shape shape);
660 635
661EAPI const Ecore_Win32_Cursor *ecore_win32_cursor_x11_shaped_get(Ecore_Win32_Cursor_X11_Shape shape); 636ECORE_WIN32_API const Ecore_Win32_Cursor *ecore_win32_cursor_x11_shaped_get(Ecore_Win32_Cursor_X11_Shape shape);
662 637
663EAPI void ecore_win32_cursor_size_get(int *width, int *height); 638ECORE_WIN32_API void ecore_win32_cursor_size_get(int *width, int *height);
664 639
665EAPI void ecore_win32_cursor_show(Eina_Bool show); 640ECORE_WIN32_API void ecore_win32_cursor_show(Eina_Bool show);
666 641
667 642
668 643
669/* Drag and drop */ 644/* Drag and drop */
670EAPI int ecore_win32_dnd_init(); 645ECORE_WIN32_API int ecore_win32_dnd_init();
671EAPI int ecore_win32_dnd_shutdown(); 646ECORE_WIN32_API int ecore_win32_dnd_shutdown();
672EAPI Eina_Bool ecore_win32_dnd_begin(const char *data, 647ECORE_WIN32_API Eina_Bool ecore_win32_dnd_begin(const char *data,
673 int size); 648 int size);
674EAPI Eina_Bool ecore_win32_dnd_register_drop_target(Ecore_Win32_Window *window, 649ECORE_WIN32_API Eina_Bool ecore_win32_dnd_register_drop_target(Ecore_Win32_Window *window,
675 Ecore_Win32_Dnd_DropTarget_Callback callback); 650 Ecore_Win32_Dnd_DropTarget_Callback callback);
676EAPI void ecore_win32_dnd_unregister_drop_target(Ecore_Win32_Window *window); 651ECORE_WIN32_API void ecore_win32_dnd_unregister_drop_target(Ecore_Win32_Window *window);
677 652
678/* Clipboard */ 653/* Clipboard */
679 654
@@ -693,7 +668,7 @@ EAPI void ecore_win32_dnd_unregister_drop_target(Ecore_Win32_Window *window
693 * 668 *
694 * @since 1.24 669 * @since 1.24
695 */ 670 */
696EAPI Eina_Bool ecore_win32_clipboard_set(const Ecore_Win32_Window *window, 671ECORE_WIN32_API Eina_Bool ecore_win32_clipboard_set(const Ecore_Win32_Window *window,
697 const void *data, 672 const void *data,
698 size_t size, 673 size_t size,
699 const char *mime_type); 674 const char *mime_type);
@@ -711,7 +686,7 @@ EAPI Eina_Bool ecore_win32_clipboard_set(const Ecore_Win32_Window *window,
711 * 686 *
712 * @since 1.24 687 * @since 1.24
713 */ 688 */
714EAPI void * ecore_win32_clipboard_get(const Ecore_Win32_Window *window, 689ECORE_WIN32_API void * ecore_win32_clipboard_get(const Ecore_Win32_Window *window,
715 size_t *size, 690 size_t *size,
716 const char *mime_type); 691 const char *mime_type);
717 692
@@ -726,7 +701,7 @@ EAPI void * ecore_win32_clipboard_get(const Ecore_Win32_Window *window,
726 * 701 *
727 * @since 1.24 702 * @since 1.24
728 */ 703 */
729EAPI void ecore_win32_clipboard_clear(const Ecore_Win32_Window *window); 704ECORE_WIN32_API void ecore_win32_clipboard_clear(const Ecore_Win32_Window *window);
730 705
731/** 706/**
732 * @typedef Ecore_Win32_Monitor 707 * @typedef Ecore_Win32_Monitor
@@ -755,7 +730,7 @@ typedef struct
755 * 730 *
756 * @since 1.20 731 * @since 1.20
757 */ 732 */
758EAPI Eina_Iterator *ecore_win32_monitors_get(void); 733ECORE_WIN32_API Eina_Iterator *ecore_win32_monitors_get(void);
759 734
760/** 735/**
761 * @} 736 * @}
@@ -765,7 +740,4 @@ EAPI Eina_Iterator *ecore_win32_monitors_get(void);
765} 740}
766#endif 741#endif
767 742
768#undef EAPI
769#define EAPI
770
771#endif /* __ECORE_WIN32_H__ */ 743#endif /* __ECORE_WIN32_H__ */
diff --git a/src/lib/ecore_win32/ecore_win32.c b/src/lib/ecore_win32/ecore_win32.c
index 1ee8b2fbdf..b5cbf7c6e9 100644
--- a/src/lib/ecore_win32/ecore_win32.c
+++ b/src/lib/ecore_win32/ecore_win32.c
@@ -470,7 +470,7 @@ int ECORE_WIN32_EVENT_SELECTION_NOTIFY = 0;
470 * When Ecore_Win32 is not used anymore, call ecore_win32_shutdown() 470 * When Ecore_Win32 is not used anymore, call ecore_win32_shutdown()
471 * to shut down the Ecore_Win32 library. 471 * to shut down the Ecore_Win32 library.
472 */ 472 */
473EAPI int 473ECORE_WIN32_API int
474ecore_win32_init() 474ecore_win32_init()
475{ 475{
476 WNDCLASSEX wc; 476 WNDCLASSEX wc;
@@ -595,7 +595,7 @@ ecore_win32_init()
595 * been called the same number of times than ecore_win32_init(). In that case 595 * been called the same number of times than ecore_win32_init(). In that case
596 * it shuts down all the Windows graphic system. 596 * it shuts down all the Windows graphic system.
597 */ 597 */
598EAPI int 598ECORE_WIN32_API int
599ecore_win32_shutdown() 599ecore_win32_shutdown()
600{ 600{
601 int i; 601 int i;
@@ -650,7 +650,7 @@ ecore_win32_shutdown()
650 * This function returns the depth of the screen. If an error occurs, 650 * This function returns the depth of the screen. If an error occurs,
651 * it returns 0. 651 * it returns 0.
652 */ 652 */
653EAPI int 653ECORE_WIN32_API int
654ecore_win32_screen_depth_get() 654ecore_win32_screen_depth_get()
655{ 655{
656 HDC dc; 656 HDC dc;
@@ -683,7 +683,7 @@ ecore_win32_screen_depth_get()
683 * double_click flag is set in a button down event. If 3 clicks occur 683 * double_click flag is set in a button down event. If 3 clicks occur
684 * within double this time, the triple_click flag is also set. 684 * within double this time, the triple_click flag is also set.
685 */ 685 */
686EAPI void 686ECORE_WIN32_API void
687ecore_win32_double_click_time_set(double t) 687ecore_win32_double_click_time_set(double t)
688{ 688{
689 if (t < 0.0) t = 0.0; 689 if (t < 0.0) t = 0.0;
@@ -700,7 +700,7 @@ ecore_win32_double_click_time_set(double t)
700 * default value is returned. See ecore_win32_double_click_time_set() 700 * default value is returned. See ecore_win32_double_click_time_set()
701 * for more informations. 701 * for more informations.
702 */ 702 */
703EAPI double 703ECORE_WIN32_API double
704ecore_win32_double_click_time_get(void) 704ecore_win32_double_click_time_get(void)
705{ 705{
706 return _ecore_win32_double_click_time; 706 return _ecore_win32_double_click_time;
@@ -713,7 +713,7 @@ ecore_win32_double_click_time_get(void)
713 * 713 *
714 * This function returns the last event time. 714 * This function returns the last event time.
715 */ 715 */
716EAPI unsigned long 716ECORE_WIN32_API unsigned long
717ecore_win32_current_time_get(void) 717ecore_win32_current_time_get(void)
718{ 718{
719 return _ecore_win32_event_last_time; 719 return _ecore_win32_event_last_time;
diff --git a/src/lib/ecore_win32/ecore_win32_api.h b/src/lib/ecore_win32/ecore_win32_api.h
new file mode 100644
index 0000000000..1540131361
--- /dev/null
+++ b/src/lib/ecore_win32/ecore_win32_api.h
@@ -0,0 +1,34 @@
1#ifndef _EFL_ECORE_WIN32_API_H
2#define _EFL_ECORE_WIN32_API_H
3
4#ifdef ECORE_WIN32_API
5#error ECORE_WIN32_API should not be already defined
6#endif
7
8#ifdef _WIN32
9# ifndef ECORE_WIN32_STATIC
10# ifdef ECORE_WIN32_BUILD
11# define ECORE_WIN32_API __declspec(dllexport)
12# else
13# define ECORE_WIN32_API __declspec(dllimport)
14# endif
15# else
16# define ECORE_WIN32_API
17# endif
18# define ECORE_WIN32_API_WEAK
19#else
20# ifdef __GNUC__
21# if __GNUC__ >= 4
22# define ECORE_WIN32_API __attribute__ ((visibility("default")))
23# define ECORE_WIN32_API_WEAK __attribute__ ((weak))
24# else
25# define ECORE_WIN32_API
26# define ECORE_WIN32_API_WEAK
27# endif
28# else
29# define ECORE_WIN32_API
30# define ECORE_WIN32_API_WEAK
31# endif
32#endif
33
34#endif
diff --git a/src/lib/ecore_win32/ecore_win32_clipboard.c b/src/lib/ecore_win32/ecore_win32_clipboard.c
index da4960370a..abe5141929 100644
--- a/src/lib/ecore_win32/ecore_win32_clipboard.c
+++ b/src/lib/ecore_win32/ecore_win32_clipboard.c
@@ -37,7 +37,7 @@
37 *============================================================================*/ 37 *============================================================================*/
38 38
39 39
40EAPI Eina_Bool 40ECORE_WIN32_API Eina_Bool
41ecore_win32_clipboard_set(const Ecore_Win32_Window *window, 41ecore_win32_clipboard_set(const Ecore_Win32_Window *window,
42 const void *data, 42 const void *data,
43 size_t size, 43 size_t size,
@@ -121,7 +121,7 @@ ecore_win32_clipboard_set(const Ecore_Win32_Window *window,
121 return res; 121 return res;
122} 122}
123 123
124EAPI void * 124ECORE_WIN32_API void *
125ecore_win32_clipboard_get(const Ecore_Win32_Window *window, 125ecore_win32_clipboard_get(const Ecore_Win32_Window *window,
126 size_t *size, 126 size_t *size,
127 const char *mime_type) 127 const char *mime_type)
@@ -225,7 +225,7 @@ ecore_win32_clipboard_get(const Ecore_Win32_Window *window,
225 return NULL; 225 return NULL;
226} 226}
227 227
228EAPI void 228ECORE_WIN32_API void
229ecore_win32_clipboard_clear(const Ecore_Win32_Window *window) 229ecore_win32_clipboard_clear(const Ecore_Win32_Window *window)
230{ 230{
231 INF("clearing the clipboard"); 231 INF("clearing the clipboard");
diff --git a/src/lib/ecore_win32/ecore_win32_cursor.c b/src/lib/ecore_win32/ecore_win32_cursor.c
index 490e4f4ec9..53483858c7 100644
--- a/src/lib/ecore_win32/ecore_win32_cursor.c
+++ b/src/lib/ecore_win32/ecore_win32_cursor.c
@@ -181,7 +181,7 @@ _ecore_win32_cursor_x11_shaped_new(Ecore_Win32_Cursor_X11_Shape shape)
181 * @see ecore_win32_cursor_free() 181 * @see ecore_win32_cursor_free()
182 * @see ecore_win32_window_cursor_set() 182 * @see ecore_win32_window_cursor_set()
183 */ 183 */
184EAPI Ecore_Win32_Cursor * 184ECORE_WIN32_API Ecore_Win32_Cursor *
185ecore_win32_cursor_new(const void *pixels_and, 185ecore_win32_cursor_new(const void *pixels_and,
186 const void *pixels_xor, 186 const void *pixels_xor,
187 int width, 187 int width,
@@ -226,7 +226,7 @@ ecore_win32_cursor_new(const void *pixels_and,
226 * @see ecore_win32_cursor_new() 226 * @see ecore_win32_cursor_new()
227 * @see ecore_win32_cursor_x11_shaped_new() 227 * @see ecore_win32_cursor_x11_shaped_new()
228 */ 228 */
229EAPI void 229ECORE_WIN32_API void
230ecore_win32_cursor_free(Ecore_Win32_Cursor *cursor) 230ecore_win32_cursor_free(Ecore_Win32_Cursor *cursor)
231{ 231{
232 INF("destroying cursor"); 232 INF("destroying cursor");
@@ -247,7 +247,7 @@ ecore_win32_cursor_free(Ecore_Win32_Cursor *cursor)
247 * @p shape. This cursor does not need to be freed, as it is loaded 247 * @p shape. This cursor does not need to be freed, as it is loaded
248 * from an existing resource. On error @c NULL is returned. 248 * from an existing resource. On error @c NULL is returned.
249 */ 249 */
250EAPI Ecore_Win32_Cursor * 250ECORE_WIN32_API Ecore_Win32_Cursor *
251ecore_win32_cursor_shaped_new(Ecore_Win32_Cursor_Shape shape) 251ecore_win32_cursor_shaped_new(Ecore_Win32_Cursor_Shape shape)
252{ 252{
253 Ecore_Win32_Cursor *cursor = NULL; 253 Ecore_Win32_Cursor *cursor = NULL;
@@ -324,7 +324,7 @@ ecore_win32_cursor_shaped_new(Ecore_Win32_Cursor_Shape shape)
324 * 324 *
325 * @since 1.16 325 * @since 1.16
326 */ 326 */
327EAPI const Ecore_Win32_Cursor * 327ECORE_WIN32_API const Ecore_Win32_Cursor *
328ecore_win32_cursor_x11_shaped_get(Ecore_Win32_Cursor_X11_Shape shape) 328ecore_win32_cursor_x11_shaped_get(Ecore_Win32_Cursor_X11_Shape shape)
329{ 329{
330 INF("getting X11 shaped cursor"); 330 INF("getting X11 shaped cursor");
@@ -346,7 +346,7 @@ ecore_win32_cursor_x11_shaped_get(Ecore_Win32_Cursor_X11_Shape shape)
346 * ecore_win32_cursor_new(). @p width and @p height are buffers that 346 * ecore_win32_cursor_new(). @p width and @p height are buffers that
347 * will be filled with the correct size. They can be @c NULL. 347 * will be filled with the correct size. They can be @c NULL.
348 */ 348 */
349EAPI void 349ECORE_WIN32_API void
350ecore_win32_cursor_size_get(int *width, int *height) 350ecore_win32_cursor_size_get(int *width, int *height)
351{ 351{
352 INF("geting size cursor"); 352 INF("geting size cursor");
@@ -355,7 +355,7 @@ ecore_win32_cursor_size_get(int *width, int *height)
355 if (*height) *height = GetSystemMetrics(SM_CYCURSOR); 355 if (*height) *height = GetSystemMetrics(SM_CYCURSOR);
356} 356}
357 357
358EAPI void 358ECORE_WIN32_API void
359ecore_win32_cursor_show(Eina_Bool show) 359ecore_win32_cursor_show(Eina_Bool show)
360{ 360{
361 INF("show cursor"); 361 INF("show cursor");
diff --git a/src/lib/ecore_win32/ecore_win32_dnd.c b/src/lib/ecore_win32/ecore_win32_dnd.c
index a99d26c524..5a28ea69b8 100644
--- a/src/lib/ecore_win32/ecore_win32_dnd.c
+++ b/src/lib/ecore_win32/ecore_win32_dnd.c
@@ -58,7 +58,7 @@ static HANDLE DataToHandle(const char *data, int size)
58 * When the Drag and Drop module is not used anymore, call 58 * When the Drag and Drop module is not used anymore, call
59 * ecore_win32_dnd_shutdown() to shut down the module. 59 * ecore_win32_dnd_shutdown() to shut down the module.
60 */ 60 */
61EAPI int 61ECORE_WIN32_API int
62ecore_win32_dnd_init() 62ecore_win32_dnd_init()
63{ 63{
64 HRESULT res; 64 HRESULT res;
@@ -91,7 +91,7 @@ ecore_win32_dnd_init()
91 * been called the same number of times than ecore_win32_dnd_init(). In that case 91 * been called the same number of times than ecore_win32_dnd_init(). In that case
92 * it shut down the module. 92 * it shut down the module.
93 */ 93 */
94EAPI int 94ECORE_WIN32_API int
95ecore_win32_dnd_shutdown() 95ecore_win32_dnd_shutdown()
96{ 96{
97 _ecore_win32_dnd_init_count--; 97 _ecore_win32_dnd_init_count--;
@@ -116,7 +116,7 @@ ecore_win32_dnd_shutdown()
116 * @c 0, it is set to the length (as strlen()) of @p data. On success the 116 * @c 0, it is set to the length (as strlen()) of @p data. On success the
117 * function returns @c EINA_TRUE, otherwise it returns @c EINA_FALSE. 117 * function returns @c EINA_TRUE, otherwise it returns @c EINA_FALSE.
118 */ 118 */
119EAPI Eina_Bool 119ECORE_WIN32_API Eina_Bool
120ecore_win32_dnd_begin(const char *data, 120ecore_win32_dnd_begin(const char *data,
121 int size) 121 int size)
122{ 122{
@@ -187,7 +187,7 @@ ecore_win32_dnd_begin(const char *data,
187 * the function returns @c EINA_FALSE. On success, it returns @c EINA_TRUE, 187 * the function returns @c EINA_FALSE. On success, it returns @c EINA_TRUE,
188 * otherwise it returns @c EINA_FALSE. 188 * otherwise it returns @c EINA_FALSE.
189 */ 189 */
190EAPI Eina_Bool 190ECORE_WIN32_API Eina_Bool
191ecore_win32_dnd_register_drop_target(Ecore_Win32_Window *window, 191ecore_win32_dnd_register_drop_target(Ecore_Win32_Window *window,
192 Ecore_Win32_Dnd_DropTarget_Callback callback) 192 Ecore_Win32_Dnd_DropTarget_Callback callback)
193{ 193{
@@ -210,7 +210,7 @@ ecore_win32_dnd_register_drop_target(Ecore_Win32_Window *window,
210 * This function unregister a Drop operation on @p window. If 210 * This function unregister a Drop operation on @p window. If
211 * @p window is @c NULL, the function does nothing. 211 * @p window is @c NULL, the function does nothing.
212 */ 212 */
213EAPI void 213ECORE_WIN32_API void
214ecore_win32_dnd_unregister_drop_target(Ecore_Win32_Window *window) 214ecore_win32_dnd_unregister_drop_target(Ecore_Win32_Window *window)
215{ 215{
216 Ecore_Win32_Window *wnd = (Ecore_Win32_Window *)window; 216 Ecore_Win32_Window *wnd = (Ecore_Win32_Window *)window;
diff --git a/src/lib/ecore_win32/ecore_win32_monitor.c b/src/lib/ecore_win32/ecore_win32_monitor.c
index 36d136908e..63ce931095 100644
--- a/src/lib/ecore_win32/ecore_win32_monitor.c
+++ b/src/lib/ecore_win32/ecore_win32_monitor.c
@@ -217,7 +217,7 @@ ecore_win32_monitor_update(int d)
217 * API * 217 * API *
218 *============================================================================*/ 218 *============================================================================*/
219 219
220EAPI Eina_Iterator * 220ECORE_WIN32_API Eina_Iterator *
221ecore_win32_monitors_get(void) 221ecore_win32_monitors_get(void)
222{ 222{
223 return eina_list_iterator_new(ecore_win32_monitors); 223 return eina_list_iterator_new(ecore_win32_monitors);
diff --git a/src/lib/ecore_win32/ecore_win32_window.c b/src/lib/ecore_win32/ecore_win32_window.c
index 628264d7b3..2378e356d9 100644
--- a/src/lib/ecore_win32/ecore_win32_window.c
+++ b/src/lib/ecore_win32/ecore_win32_window.c
@@ -445,7 +445,7 @@ ecore_win32_window_drag(Ecore_Win32_Window *w, int ptx, int pty)
445 * title bar). This function returns a newly created window on 445 * title bar). This function returns a newly created window on
446 * success, and @c NULL on failure. 446 * success, and @c NULL on failure.
447 */ 447 */
448EAPI Ecore_Win32_Window * 448ECORE_WIN32_API Ecore_Win32_Window *
449ecore_win32_window_new(Ecore_Win32_Window *parent, 449ecore_win32_window_new(Ecore_Win32_Window *parent,
450 int x, 450 int x,
451 int y, 451 int y,
@@ -473,7 +473,7 @@ ecore_win32_window_new(Ecore_Win32_Window *parent,
473 * This function is the same than ecore_win32_window_override_new() 473 * This function is the same than ecore_win32_window_override_new()
474 * but the returned window is borderless. 474 * but the returned window is borderless.
475 */ 475 */
476EAPI Ecore_Win32_Window * 476ECORE_WIN32_API Ecore_Win32_Window *
477ecore_win32_window_override_new(Ecore_Win32_Window *parent, 477ecore_win32_window_override_new(Ecore_Win32_Window *parent,
478 int x, 478 int x,
479 int y, 479 int y,
@@ -496,7 +496,7 @@ ecore_win32_window_override_new(Ecore_Win32_Window *parent,
496 * This function frees @p window. If @p window is @c NULL, this 496 * This function frees @p window. If @p window is @c NULL, this
497 * function does nothing. 497 * function does nothing.
498 */ 498 */
499EAPI void 499ECORE_WIN32_API void
500ecore_win32_window_free(Ecore_Win32_Window *window) 500ecore_win32_window_free(Ecore_Win32_Window *window)
501{ 501{
502 if (!window) return; 502 if (!window) return;
@@ -520,7 +520,7 @@ ecore_win32_window_free(Ecore_Win32_Window *window)
520 * 520 *
521 * @note The returned value is of type HWND. 521 * @note The returned value is of type HWND.
522 */ 522 */
523EAPI void * 523ECORE_WIN32_API void *
524ecore_win32_window_hwnd_get(Ecore_Win32_Window *window) 524ecore_win32_window_hwnd_get(Ecore_Win32_Window *window)
525{ 525{
526 if (!window) return NULL; 526 if (!window) return NULL;
@@ -571,7 +571,7 @@ ecore_win32_window_configure(Ecore_Win32_Window *window,
571 * and @p y. If @p window is @c NULL, or if it is fullscreen, or on 571 * and @p y. If @p window is @c NULL, or if it is fullscreen, or on
572 * error, this function does nothing. 572 * error, this function does nothing.
573 */ 573 */
574EAPI void 574ECORE_WIN32_API void
575ecore_win32_window_move(Ecore_Win32_Window *window, 575ecore_win32_window_move(Ecore_Win32_Window *window,
576 int x, 576 int x,
577 int y) 577 int y)
@@ -609,7 +609,7 @@ ecore_win32_window_move(Ecore_Win32_Window *window,
609 * If @p window is @c NULL, or if it is fullscreen, or on error, this 609 * If @p window is @c NULL, or if it is fullscreen, or on error, this
610 * function does nothing. 610 * function does nothing.
611 */ 611 */
612EAPI void 612ECORE_WIN32_API void
613ecore_win32_window_resize(Ecore_Win32_Window *window, 613ecore_win32_window_resize(Ecore_Win32_Window *window,
614 int width, 614 int width,
615 int height) 615 int height)
@@ -673,7 +673,7 @@ ecore_win32_window_resize(Ecore_Win32_Window *window,
673 * and @p y and the new @p width and @p height. If @p window is @c NULL, 673 * and @p y and the new @p width and @p height. If @p window is @c NULL,
674 * or if it is fullscreen, or on error, this function does nothing. 674 * or if it is fullscreen, or on error, this function does nothing.
675 */ 675 */
676EAPI void 676ECORE_WIN32_API void
677ecore_win32_window_move_resize(Ecore_Win32_Window *window, 677ecore_win32_window_move_resize(Ecore_Win32_Window *window,
678 int x, 678 int x,
679 int y, 679 int y,
@@ -732,7 +732,7 @@ ecore_win32_window_move_resize(Ecore_Win32_Window *window,
732 * buffers are not @c NULL, they will be filled with respectively 0, 732 * buffers are not @c NULL, they will be filled with respectively 0,
733 * 0, the size of the screen and the height of the screen. 733 * 0, the size of the screen and the height of the screen.
734 */ 734 */
735EAPI void 735ECORE_WIN32_API void
736ecore_win32_window_geometry_get(Ecore_Win32_Window *window, 736ecore_win32_window_geometry_get(Ecore_Win32_Window *window,
737 int *x, 737 int *x,
738 int *y, 738 int *y,
@@ -802,7 +802,7 @@ ecore_win32_window_geometry_get(Ecore_Win32_Window *window,
802 * @c NULL, they will be filled with respectively the size of the screen 802 * @c NULL, they will be filled with respectively the size of the screen
803 * and the height of the screen. 803 * and the height of the screen.
804 */ 804 */
805EAPI void 805ECORE_WIN32_API void
806ecore_win32_window_size_get(Ecore_Win32_Window *window, 806ecore_win32_window_size_get(Ecore_Win32_Window *window,
807 int *width, 807 int *width,
808 int *height) 808 int *height)
@@ -842,7 +842,7 @@ ecore_win32_window_size_get(Ecore_Win32_Window *window,
842 * and *p min_height. If @p window is @c NULL, this functions does 842 * and *p min_height. If @p window is @c NULL, this functions does
843 * nothing. 843 * nothing.
844 */ 844 */
845EAPI void 845ECORE_WIN32_API void
846ecore_win32_window_size_min_set(Ecore_Win32_Window *window, 846ecore_win32_window_size_min_set(Ecore_Win32_Window *window,
847 int min_width, 847 int min_width,
848 int min_height) 848 int min_height)
@@ -878,7 +878,7 @@ ecore_win32_window_size_min_set(Ecore_Win32_Window *window,
878 * @p min_width and *p min_height. They both can be @c NULL. If 878 * @p min_width and *p min_height. They both can be @c NULL. If
879 * @p window is @c NULL, this functions does nothing. 879 * @p window is @c NULL, this functions does nothing.
880 */ 880 */
881EAPI void 881ECORE_WIN32_API void
882ecore_win32_window_size_min_get(Ecore_Win32_Window *window, 882ecore_win32_window_size_min_get(Ecore_Win32_Window *window,
883 int *min_width, 883 int *min_width,
884 int *min_height) 884 int *min_height)
@@ -907,7 +907,7 @@ ecore_win32_window_size_min_get(Ecore_Win32_Window *window,
907 * and *p max_height. If @p window is @c NULL, this functions does 907 * and *p max_height. If @p window is @c NULL, this functions does
908 * nothing. 908 * nothing.
909 */ 909 */
910EAPI void 910ECORE_WIN32_API void
911ecore_win32_window_size_max_set(Ecore_Win32_Window *window, 911ecore_win32_window_size_max_set(Ecore_Win32_Window *window,
912 int max_width, 912 int max_width,
913 int max_height) 913 int max_height)
@@ -935,7 +935,7 @@ ecore_win32_window_size_max_set(Ecore_Win32_Window *window,
935 * @p max_width and *p max_height. They both can be @c NULL. If 935 * @p max_width and *p max_height. They both can be @c NULL. If
936 * @p window is @c NULL, this functions does nothing. 936 * @p window is @c NULL, this functions does nothing.
937 */ 937 */
938EAPI void 938ECORE_WIN32_API void
939ecore_win32_window_size_max_get(Ecore_Win32_Window *window, 939ecore_win32_window_size_max_get(Ecore_Win32_Window *window,
940 int *max_width, 940 int *max_width,
941 int *max_height) 941 int *max_height)
@@ -964,7 +964,7 @@ ecore_win32_window_size_max_get(Ecore_Win32_Window *window,
964 * and *p base_height. If @p window is @c NULL, this functions does 964 * and *p base_height. If @p window is @c NULL, this functions does
965 * nothing. 965 * nothing.
966 */ 966 */
967EAPI void 967ECORE_WIN32_API void
968ecore_win32_window_size_base_set(Ecore_Win32_Window *window, 968ecore_win32_window_size_base_set(Ecore_Win32_Window *window,
969 int base_width, 969 int base_width,
970 int base_height) 970 int base_height)
@@ -992,7 +992,7 @@ ecore_win32_window_size_base_set(Ecore_Win32_Window *window,
992 * @p base_width and *p base_height. They both can be @c NULL. If 992 * @p base_width and *p base_height. They both can be @c NULL. If
993 * @p window is @c NULL, this functions does nothing. 993 * @p window is @c NULL, this functions does nothing.
994 */ 994 */
995EAPI void 995ECORE_WIN32_API void
996ecore_win32_window_size_base_get(Ecore_Win32_Window *window, 996ecore_win32_window_size_base_get(Ecore_Win32_Window *window,
997 int *base_width, 997 int *base_width,
998 int *base_height) 998 int *base_height)
@@ -1021,7 +1021,7 @@ ecore_win32_window_size_base_get(Ecore_Win32_Window *window,
1021 * and *p step_height. If @p window is @c NULL, this functions does 1021 * and *p step_height. If @p window is @c NULL, this functions does
1022 * nothing. 1022 * nothing.
1023 */ 1023 */
1024EAPI void 1024ECORE_WIN32_API void
1025ecore_win32_window_size_step_set(Ecore_Win32_Window *window, 1025ecore_win32_window_size_step_set(Ecore_Win32_Window *window,
1026 int step_width, 1026 int step_width,
1027 int step_height) 1027 int step_height)
@@ -1049,7 +1049,7 @@ ecore_win32_window_size_step_set(Ecore_Win32_Window *window,
1049 * @p step_width and *p step_height. They both can be @c NULL. If 1049 * @p step_width and *p step_height. They both can be @c NULL. If
1050 * @p window is @c NULL, this functions does nothing. 1050 * @p window is @c NULL, this functions does nothing.
1051 */ 1051 */
1052EAPI void 1052ECORE_WIN32_API void
1053ecore_win32_window_size_step_get(Ecore_Win32_Window *window, 1053ecore_win32_window_size_step_get(Ecore_Win32_Window *window,
1054 int *step_width, 1054 int *step_width,
1055 int *step_height) 1055 int *step_height)
@@ -1075,7 +1075,7 @@ ecore_win32_window_size_step_get(Ecore_Win32_Window *window,
1075 * This function shows @p window. If @p window is @c NULL, or on 1075 * This function shows @p window. If @p window is @c NULL, or on
1076 * error, this function does nothing. 1076 * error, this function does nothing.
1077 */ 1077 */
1078EAPI void 1078ECORE_WIN32_API void
1079ecore_win32_window_show(Ecore_Win32_Window *window) 1079ecore_win32_window_show(Ecore_Win32_Window *window)
1080{ 1080{
1081 if (!window) return; 1081 if (!window) return;
@@ -1098,7 +1098,7 @@ ecore_win32_window_show(Ecore_Win32_Window *window)
1098 * This function hides @p window. If @p window is @c NULL, or on 1098 * This function hides @p window. If @p window is @c NULL, or on
1099 * error, this function does nothing. 1099 * error, this function does nothing.
1100 */ 1100 */
1101EAPI void 1101ECORE_WIN32_API void
1102ecore_win32_window_hide(Ecore_Win32_Window *window) 1102ecore_win32_window_hide(Ecore_Win32_Window *window)
1103{ 1103{
1104 if (!window) return; 1104 if (!window) return;
@@ -1116,7 +1116,7 @@ ecore_win32_window_hide(Ecore_Win32_Window *window)
1116 * This function places @p window at the top of the Z order. If 1116 * This function places @p window at the top of the Z order. If
1117 * @p window is @c NULL, this function does nothing. 1117 * @p window is @c NULL, this function does nothing.
1118 */ 1118 */
1119EAPI void 1119ECORE_WIN32_API void
1120ecore_win32_window_raise(Ecore_Win32_Window *window) 1120ecore_win32_window_raise(Ecore_Win32_Window *window)
1121{ 1121{
1122 if (!window) return; 1122 if (!window) return;
@@ -1139,7 +1139,7 @@ ecore_win32_window_raise(Ecore_Win32_Window *window)
1139 * This function places @p window at the bottom of the Z order. If 1139 * This function places @p window at the bottom of the Z order. If
1140 * @p window is @c NULL, this function does nothing. 1140 * @p window is @c NULL, this function does nothing.
1141 */ 1141 */
1142EAPI void 1142ECORE_WIN32_API void
1143ecore_win32_window_lower(Ecore_Win32_Window *window) 1143ecore_win32_window_lower(Ecore_Win32_Window *window)
1144{ 1144{
1145 if (!window) return; 1145 if (!window) return;
@@ -1164,7 +1164,7 @@ ecore_win32_window_lower(Ecore_Win32_Window *window)
1164 * is @c NULL, or if @p title is @c NULL or empty, or on error, this 1164 * is @c NULL, or if @p title is @c NULL or empty, or on error, this
1165 * function does nothing. 1165 * function does nothing.
1166 */ 1166 */
1167EAPI void 1167ECORE_WIN32_API void
1168ecore_win32_window_title_set(Ecore_Win32_Window *window, 1168ecore_win32_window_title_set(Ecore_Win32_Window *window,
1169 const char *title) 1169 const char *title)
1170{ 1170{
@@ -1188,7 +1188,7 @@ ecore_win32_window_title_set(Ecore_Win32_Window *window,
1188 * This function gives the focus to @p window. If @p window is 1188 * This function gives the focus to @p window. If @p window is
1189 * @c NULL, this function does nothing. 1189 * @c NULL, this function does nothing.
1190 */ 1190 */
1191EAPI void 1191ECORE_WIN32_API void
1192ecore_win32_window_focus(Ecore_Win32_Window *window) 1192ecore_win32_window_focus(Ecore_Win32_Window *window)
1193{ 1193{
1194 if (!window) return; 1194 if (!window) return;
@@ -1215,7 +1215,7 @@ ecore_win32_window_focus(Ecore_Win32_Window *window)
1215 * 1215 *
1216 * @note The returned value is of type HWND. 1216 * @note The returned value is of type HWND.
1217 */ 1217 */
1218EAPI void * 1218ECORE_WIN32_API void *
1219ecore_win32_window_focus_get(void) 1219ecore_win32_window_focus_get(void)
1220{ 1220{
1221 HWND focused; 1221 HWND focused;
@@ -1244,7 +1244,7 @@ ecore_win32_window_focus_get(void)
1244 * (like iconifying the window while it is already iconified), this function 1244 * (like iconifying the window while it is already iconified), this function
1245 * does nothing. 1245 * does nothing.
1246 */ 1246 */
1247EAPI void 1247ECORE_WIN32_API void
1248ecore_win32_window_iconified_set(Ecore_Win32_Window *window, 1248ecore_win32_window_iconified_set(Ecore_Win32_Window *window,
1249 Eina_Bool on) 1249 Eina_Bool on)
1250{ 1250{
@@ -1272,7 +1272,7 @@ ecore_win32_window_iconified_set(Ecore_Win32_Window *window,
1272 * change (like setting to borderless while the window has no border), this 1272 * change (like setting to borderless while the window has no border), this
1273 * function does nothing. 1273 * function does nothing.
1274 */ 1274 */
1275EAPI void 1275ECORE_WIN32_API void
1276ecore_win32_window_borderless_set(Ecore_Win32_Window *window, 1276ecore_win32_window_borderless_set(Ecore_Win32_Window *window,
1277 Eina_Bool on) 1277 Eina_Bool on)
1278{ 1278{
@@ -1348,7 +1348,7 @@ ecore_win32_window_borderless_set(Ecore_Win32_Window *window,
1348 * does not change (like setting to fullscreen while the window is already 1348 * does not change (like setting to fullscreen while the window is already
1349 * fullscreen), this function does nothing. 1349 * fullscreen), this function does nothing.
1350 */ 1350 */
1351EAPI void 1351ECORE_WIN32_API void
1352ecore_win32_window_fullscreen_set(Ecore_Win32_Window *window, 1352ecore_win32_window_fullscreen_set(Ecore_Win32_Window *window,
1353 Eina_Bool on) 1353 Eina_Bool on)
1354{ 1354{
@@ -1447,7 +1447,7 @@ ecore_win32_window_fullscreen_set(Ecore_Win32_Window *window,
1447 * @see ecore_win32_cursor_shaped_new() 1447 * @see ecore_win32_cursor_shaped_new()
1448 * @see ecore_win32_cursor_x11_shaped_new() 1448 * @see ecore_win32_cursor_x11_shaped_new()
1449 */ 1449 */
1450EAPI void 1450ECORE_WIN32_API void
1451ecore_win32_window_cursor_set(Ecore_Win32_Window *window, 1451ecore_win32_window_cursor_set(Ecore_Win32_Window *window,
1452 Ecore_Win32_Cursor *cursor) 1452 Ecore_Win32_Cursor *cursor)
1453{ 1453{
@@ -1470,7 +1470,7 @@ ecore_win32_window_cursor_set(Ecore_Win32_Window *window,
1470 * states of size @p num. If @p window or @p state are @c NULL, or if 1470 * states of size @p num. If @p window or @p state are @c NULL, or if
1471 * @p num is less or equal than 0, the function does nothing. 1471 * @p num is less or equal than 0, the function does nothing.
1472 */ 1472 */
1473EAPI void 1473ECORE_WIN32_API void
1474ecore_win32_window_state_set(Ecore_Win32_Window *window, 1474ecore_win32_window_state_set(Ecore_Win32_Window *window,
1475 Ecore_Win32_Window_State *state, 1475 Ecore_Win32_Window_State *state,
1476 unsigned int num) 1476 unsigned int num)
@@ -1543,7 +1543,7 @@ ecore_win32_window_state_set(Ecore_Win32_Window *window,
1543 * 1543 *
1544 * @since 1.20 1544 * @since 1.20
1545 */ 1545 */
1546EAPI void 1546ECORE_WIN32_API void
1547ecore_win32_window_state_get(Ecore_Win32_Window *window, 1547ecore_win32_window_state_get(Ecore_Win32_Window *window,
1548 Ecore_Win32_Window_State **state, 1548 Ecore_Win32_Window_State **state,
1549 unsigned int *num) 1549 unsigned int *num)
@@ -1634,7 +1634,7 @@ ecore_win32_window_state_get(Ecore_Win32_Window *window,
1634 * #ECORE_WIN32_WINDOW_STATE_FULLSCREEN. If @p window is @c NULL, the 1634 * #ECORE_WIN32_WINDOW_STATE_FULLSCREEN. If @p window is @c NULL, the
1635 * function does nothing. 1635 * function does nothing.
1636 */ 1636 */
1637EAPI void 1637ECORE_WIN32_API void
1638ecore_win32_window_state_request_send(Ecore_Win32_Window *window, 1638ecore_win32_window_state_request_send(Ecore_Win32_Window *window,
1639 Ecore_Win32_Window_State state, 1639 Ecore_Win32_Window_State state,
1640 unsigned int set) 1640 unsigned int set)
@@ -1775,7 +1775,7 @@ ecore_win32_window_state_request_send(Ecore_Win32_Window *window,
1775 * This function sets the type of @p window to @p type. If 1775 * This function sets the type of @p window to @p type. If
1776 * @p window is @c NULL, the function does nothing. 1776 * @p window is @c NULL, the function does nothing.
1777 */ 1777 */
1778EAPI void 1778ECORE_WIN32_API void
1779ecore_win32_window_type_set(Ecore_Win32_Window *window, 1779ecore_win32_window_type_set(Ecore_Win32_Window *window,
1780 Ecore_Win32_Window_Type type) 1780 Ecore_Win32_Window_Type type)
1781{ 1781{
diff --git a/src/lib/ecore_win32/meson.build b/src/lib/ecore_win32/meson.build
index b105dbae91..7130d28b1d 100644
--- a/src/lib/ecore_win32/meson.build
+++ b/src/lib/ecore_win32/meson.build
@@ -31,7 +31,7 @@ if sys_windows == true
31 dependencies: [ecore_win32_deps, ecore_win32_pub_deps, ecore_win32_ext_deps], 31 dependencies: [ecore_win32_deps, ecore_win32_pub_deps, ecore_win32_ext_deps],
32 include_directories : config_dir, 32 include_directories : config_dir,
33 install: true, 33 install: true,
34 c_args : package_c_args, 34 c_args : [package_c_args, '-DECORE_WIN32_BUILD'],
35 ) 35 )
36 36
37 ecore_win32 = declare_dependency( 37 ecore_win32 = declare_dependency(