From 85fc2c8c67fe4dbfb804f2b02b6a07dbf45ad4f6 Mon Sep 17 00:00:00 2001 From: "Adam D. Ruppe" Date: Tue, 26 Dec 2017 11:35:01 -0500 Subject: [PATCH] catchup --- color.d | 8 ++++---- dom.d | 7 +++++++ gamehelpers.d | 4 ++-- simpledisplay.d | 8 +++++++- 4 files changed, 20 insertions(+), 7 deletions(-) diff --git a/color.d b/color.d index 6695802..9c2504d 100644 --- a/color.d +++ b/color.d @@ -1052,12 +1052,12 @@ body { sorted ~= ColorUse(color, count); uses = null; - version(no_phobos) - sorted = sorted.sort; - else { + //version(no_phobos) + //sorted = sorted.sort; + //else { import std.algorithm : sort; sort(sorted); - } + //} ubyte[Color] paletteAssignments; foreach(idx, entry; palette) diff --git a/dom.d b/dom.d index f8f25ae..09452a7 100644 --- a/dom.d +++ b/dom.d @@ -7051,6 +7051,13 @@ unittest { } +/ +/+ + so this currently outputs + + + + for an empty span. idk if i want that. ++/ bool allAreInlineHtml(const(Element)[] children) { foreach(child; children) { if(child.nodeType == NodeType.Text && child.nodeValue.strip.length) { diff --git a/gamehelpers.d b/gamehelpers.d index 462f277..389fd5c 100644 --- a/gamehelpers.d +++ b/gamehelpers.d @@ -115,7 +115,7 @@ class GameHelperBase { /// The virtual digital controllers are best to use if that model fits you because it /// works with several kinds of controllers as well as keyboards. - JoystickUpdate joysticks[4]; + JoystickUpdate[4] joysticks; ref JoystickUpdate joystick1() { return joysticks[0]; } bool[256] keyboardState; @@ -143,7 +143,7 @@ void runGame(T : GameHelperBase)(T game, int maxUpdateRate = 20, int maxRedrawRa readJoystickEvents(joystickFds[p]); auto update = getJoystickUpdate(p); game.joysticks[p] = update; - } else assert(0); + }// else assert(0); auto now = MonoTime.currTime; game.update(now - lastUpdate); diff --git a/simpledisplay.d b/simpledisplay.d index a18832f..aeb3cf3 100644 --- a/simpledisplay.d +++ b/simpledisplay.d @@ -2876,6 +2876,7 @@ class NotificationAreaIcon : CapableOfHandlingNativeEvent { } private void createXWin () { + // FIXME: check for MANAGER on root window to catch new/changed tray owners auto trayOwner = getTrayOwner(); if(trayOwner == None) throw new Exception("No notification area found"); @@ -3710,7 +3711,7 @@ class PosixFdReader { version(with_eventloop) { import arsd.eventloop; - addFileEventListeners(fd, &ready); + addFileEventListeners(fd, &readyel); } else { enable(); } @@ -3755,6 +3756,11 @@ class PosixFdReader { void delegate(int, bool, bool) onReady; + version(with_eventloop) + void readyel() { + onReady(fd, true, true); + } + void ready(uint flags) { static import ep = core.sys.linux.epoll; onReady(fd, (flags & ep.EPOLLIN) ? true : false, (flags & ep.EPOLLOUT) ? true : false);