ObjGUI  Check-in [0eb302cf0f]

Overview
Comment:Make it possible to use different toolkits by adding #ifdefs.
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA3-256: 0eb302cf0f063ab51d54b3a03c04a83b317e0254ec3bbbbe15b956e79ea59100
User & Date: js on 2012-01-05 01:17:35
Other Links: manifest | tags
Context
2012-01-05
14:31
Add forgotten copyright. check-in: 82ab8cf0ef user: js tags: trunk
01:17
Make it possible to use different toolkits by adding #ifdefs. check-in: 0eb302cf0f user: js tags: trunk
01:00
Add copyright and a license. check-in: ef4637f824 user: js tags: trunk
Changes

Modified gtk/Makefile from [f43900fa5f] to [e7c4fdc79d].

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
PREFIX ?= /usr/local

all:
	@objfw-compile -Wall -g --lib 0.0 -o objgui -I../headers \
		`pkg-config --cflags --libs gtk+-3.0` \
		`ls *.m | fgrep -v test.m`

test:
	@objfw-compile -Wall -g -o test -I../headers \
		`pkg-config --cflags --libs gtk+-3.0` \
		*.m

install:
	mkdir -p ${PREFIX}/include/ObjGUI
	cp ../headers/*.h ${PREFIX}/include/ObjGUI/
	cp libobjgui.so ${PREFIX}/lib/libobjgui.so.0.0



|




|







1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
PREFIX ?= /usr/local

all:
	@objfw-compile -DOG_GTK -Wall -g --lib 0.0 -o objgui -I../headers \
		`pkg-config --cflags --libs gtk+-3.0` \
		`ls *.m | fgrep -v test.m`

test:
	@objfw-compile -DOG_GTK -Wall -g -o test -I../headers \
		`pkg-config --cflags --libs gtk+-3.0` \
		*.m

install:
	mkdir -p ${PREFIX}/include/ObjGUI
	cp ../headers/*.h ${PREFIX}/include/ObjGUI/
	cp libobjgui.so ${PREFIX}/lib/libobjgui.so.0.0

Modified headers/OGApplication.h from [ac83513858] to [b05fc0e5fc].

1
2
3
4
5
6
7
8
9
#include <gtk/gtk.h>

#import <ObjFW/ObjFW.h>

@protocol OGApplicationDelegate <OFObject>
- (void)applicationDidFinishLaunching;
@optional
- (void)applicationWillTerminate;
@end
<
<









1
2
3
4
5
6
7


#import <ObjFW/ObjFW.h>

@protocol OGApplicationDelegate <OFObject>
- (void)applicationDidFinishLaunching;
@optional
- (void)applicationWillTerminate;
@end

Modified headers/OGWidget.h from [3a76e6cf99] to [d55653aa53].

16
17
18
19
20
21
22

23

24
25
26
27
28
29

30

31
32
33
34
35
36
37
 * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
 * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
 * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
 * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
 * POSSIBILITY OF SUCH DAMAGE.
 */


#include <gtk/gtk.h>


#import <ObjFW/ObjFW.h>

@interface OGWidget: OFObject
{
@public

	GtkWidget *widget;

}

- (void)show;
- (void)hide;
@end

extern void og_destroy(GtkWidget*, OGWidget*);







>
|
>






>

>







16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
 * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
 * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
 * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
 * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
 * POSSIBILITY OF SUCH DAMAGE.
 */

#ifdef OG_GTK
# include <gtk/gtk.h>
#endif

#import <ObjFW/ObjFW.h>

@interface OGWidget: OFObject
{
@public
#ifdef OG_GTK
	GtkWidget *widget;
#endif
}

- (void)show;
- (void)hide;
@end

extern void og_destroy(GtkWidget*, OGWidget*);