diff options
author | dec05eba <dec05eba@protonmail.com> | 2018-04-29 14:21:08 +0200 |
---|---|---|
committer | dec05eba <dec05eba@protonmail.com> | 2018-04-29 14:21:14 +0200 |
commit | d657a65fcb50edc9ffbcb14ab6b2815cc732709d (patch) | |
tree | 280d8de97005f14b1de629adef42204060519f90 /src | |
parent | bf83a7f1d59c50312d3d849e411d79ad79dabae7 (diff) |
Use new odhtdb with more robust ntp
Diffstat (limited to 'src')
-rw-r--r-- | src/ChannelTopPanel.cpp | 2 | ||||
-rw-r--r-- | src/MessageBoard.cpp | 2 | ||||
-rw-r--r-- | src/main.cpp | 1 |
3 files changed, 4 insertions, 1 deletions
diff --git a/src/ChannelTopPanel.cpp b/src/ChannelTopPanel.cpp index 8d9b0c8..d597353 100644 --- a/src/ChannelTopPanel.cpp +++ b/src/ChannelTopPanel.cpp @@ -71,6 +71,6 @@ namespace dchat float ChannelTopPanel::getHeight() { float fontSize = FONT_SIZE * Settings::getScaling(); - return floor(ResourceCache::getFont("fonts/Roboto-Regular.ttf")->getLineSpacing(fontSize) + PADDING_TOP + PADDING_BOTTOM); + return floor(ResourceCache::getFont("fonts/Roboto-Regular.ttf")->getLineSpacing(fontSize) + PADDING_TOP + PADDING_BOTTOM + BOTTOM_LINE_HEIGHT); } } diff --git a/src/MessageBoard.cpp b/src/MessageBoard.cpp index a2b9284..cd73c6d 100644 --- a/src/MessageBoard.cpp +++ b/src/MessageBoard.cpp @@ -184,6 +184,8 @@ namespace dchat if(position.y + LINE_HEIGHT > 0.0f && position.y < backgroundPos.y + backgroundSize.y) drawGradientLine(sf::Vector2f(position.x + LINE_SIDE_PADDING, floor(position.y)), sf::Vector2f(backgroundSizeWithoutPadding.x - LINE_SIDE_PADDING * 2.0f, LINE_HEIGHT), LINE_COLOR, window); + + position.y += LINE_HEIGHT; } totalHeight = (position.y - scroll) - startHeight; } diff --git a/src/main.cpp b/src/main.cpp index dff2328..68f9ac0 100644 --- a/src/main.cpp +++ b/src/main.cpp @@ -48,6 +48,7 @@ odhtdb::DatabaseNode createDatabaseNodeFromJoinKey(const string &joinKey) void channelAddStoredMessages(Channel *channel, const odhtdb::DatabaseStorageObjectList *nodeStorage) { + printf("Load %u messages in channel %s\n", nodeStorage->objects.size(), channel->getName().c_str()); for(auto nodeStorageAddedObject : nodeStorage->objects) { if(nodeStorageAddedObject->decryptedObject.operation == odhtdb::DatabaseOperation::ADD_DATA) |