From da09eeed1cb51496ba180d24de06380708bcf4ec Mon Sep 17 00:00:00 2001 From: Vadim Lopatin Date: Tue, 1 Apr 2014 19:30:33 +0400 Subject: [PATCH] linux app fixes --- dlanguilib.dproj | 4 ++++ examples/example1/main.d | 2 +- src/dlangui/platforms/x11/x11app.d | 17 +++++++++++++++-- 3 files changed, 20 insertions(+), 3 deletions(-) diff --git a/dlanguilib.dproj b/dlanguilib.dproj index 07988f92..06974812 100644 --- a/dlanguilib.dproj +++ b/dlanguilib.dproj @@ -175,6 +175,10 @@ + + + + diff --git a/examples/example1/main.d b/examples/example1/main.d index 74e34b01..10a1a06b 100644 --- a/examples/example1/main.d +++ b/examples/example1/main.d @@ -105,7 +105,7 @@ extern (C) int UIAppMain(string[] args) { ListWidget list = new ListWidget("tab2", Orientation.Vertical); WidgetListAdapter listAdapter = new WidgetListAdapter(); - for (int i = 0; i < 1000; i++) + for (int i = 0; i < 30; i++) listAdapter.widgets.add((new TextWidget()).text("List item "d ~ to!dstring(i))); list.ownAdapter = listAdapter; list.layoutWidth(FILL_PARENT).layoutHeight(FILL_PARENT); diff --git a/src/dlangui/platforms/x11/x11app.d b/src/dlangui/platforms/x11/x11app.d index 6bc83761..3c468cbe 100644 --- a/src/dlangui/platforms/x11/x11app.d +++ b/src/dlangui/platforms/x11/x11app.d @@ -64,7 +64,8 @@ version(linux) { uint mask; uint values[3]; - //_enableOpengl = false; + // disable opengl for testing + _enableOpengl = false; /* create black graphics context */ if (true || !_enableOpengl) { _g = xcb_generate_id(_xcbconnection); @@ -265,6 +266,16 @@ version(linux) { _drawable = _glxwindow; if (!_derelictgl3Reloaded) { + + int count; + glGetIntegerv( GL_NUM_EXTENSIONS, &count ); + Log.d("Number of extensions: ", count); + for( int i=0; i