Skip to content

Commit

Permalink
Merge with upstream v1.1.0
Browse files Browse the repository at this point in the history
Signed-off-by: Anton Filimonov <[email protected]>
  • Loading branch information
variar committed Apr 25, 2016
2 parents a13b386 + 1369f9b commit 39d98e3
Show file tree
Hide file tree
Showing 27 changed files with 282 additions and 22 deletions.
13 changes: 9 additions & 4 deletions glogg.nsi
Original file line number Diff line number Diff line change
Expand Up @@ -93,11 +93,12 @@ Section "glogg" glogg
WriteUninstaller "$INSTDIR\Uninstall.exe"
SectionEnd

Section "Qt4 Runtime libraries" qtlibs
Section "Qt5 Runtime libraries" qtlibs
SetOutPath $INSTDIR
File release\QtCore4.dll
File release\QtGui4.dll
File release\QtNetwork4.dll
File release\Qt5Core.dll
File release\Qt5Gui.dll
File release\Qt5Network.dll
File release\Qt5Widgets.dll
File release\libwinpthread-1.dll
SectionEnd

Expand Down Expand Up @@ -131,6 +132,10 @@ Section "Uninstall"
Delete "$INSTDIR\QtCore4.dll"
Delete "$INSTDIR\QtGui4.dll"
Delete "$INSTDIR\QtNetwork4.dll"
Delete "$INSTDIR\Qt5Core.dll"
Delete "$INSTDIR\Qt5Gui.dll"
Delete "$INSTDIR\Qt5Network.dll"
Delete "$INSTDIR\Qt5Widgets.dll"
Delete "$INSTDIR\libwinpthread-1.dll"
RMDir "$INSTDIR"

Expand Down
11 changes: 9 additions & 2 deletions glogg.pro
Original file line number Diff line number Diff line change
Expand Up @@ -126,8 +126,15 @@ else {
FORMS += src/optionsdialog.ui
FORMS += src/filtersdialog.ui

# For Windows icon
RC_FILE = glogg.rc
macx {
# Icon for Mac
ICON = images/glogg.icns
}
else {
# For Windows icon
RC_FILE = glogg.rc
}

RESOURCES = glogg.qrc

# Build HTML documentation (if 'markdown' is available)
Expand Down
Binary file added images/glogg.icns
Binary file not shown.
Binary file added images/glogg.iconset/.DS_Store
Binary file not shown.
Binary file added images/glogg.iconset/icon_128x128.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added images/glogg.iconset/[email protected]
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added images/glogg.iconset/icon_16x16.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added images/glogg.iconset/[email protected]
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added images/glogg.iconset/icon_256x256.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added images/glogg.iconset/[email protected]
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added images/glogg.iconset/icon_32x32.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added images/glogg.iconset/[email protected]
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added images/glogg.iconset/icon_512x512.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added images/glogg.iconset/[email protected]
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified images/open14.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified images/[email protected]
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added images/osx_installer.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
205 changes: 205 additions & 0 deletions images/osx_installer.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added images/[email protected]
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified images/reload14.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified images/[email protected]
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
10 changes: 10 additions & 0 deletions osx_installer.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
{
"title": "glogg",
"icon": "images/glogg.icns",
"background": "images/osx_installer.png",
"icon-size": 128,
"contents": [
{ "x": 415, "y": 234, "type": "link", "path": "/Applications" },
{ "x": 150, "y": 234, "type": "file", "path": "release/glogg.app" }
]
}
24 changes: 24 additions & 0 deletions release-osx.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
#!/bin/bash

# Build glogg for OSX and make a DMG installer
# (uses https://github.com/LinusU/node-appdmg)
#
# brew install node
# npm install -g appdmg
#
# QTDIR is built -static

QTDIR=$HOME/Sandbox/qt-5.5.1-release-static
BOOST_PATH=$HOME/Sandbox/boost_1_59_0

make clean
if [ -z "$VERSION" ]; then
echo Please specify a version to build: $0 VERSION=1.2.3
exit 1
else
$QTDIR/qtbase/bin/qmake glogg.pro CONFIG+="release no-dbus version_checker" BOOST_PATH=$BOOSTDIR VERSION="$VERSION"
fi
make -j8

rm glogg_${VERSION}_installer.dmg
appdmg osx_installer.json glogg_${VERSION}_installer.dmg
11 changes: 6 additions & 5 deletions release-win64-x.sh
Original file line number Diff line number Diff line change
Expand Up @@ -3,23 +3,24 @@
# Build glogg for win32 using the cross-compiler

QTXDIR=$HOME/qt-x-win32
QTVERSION=4.8.6-64
QTVERSION=5.5.1-64
BOOSTDIR=$QTXDIR/boost_1_50_0

rm release debug .obj .ui .moc -rf
make clean
if [ "$1" == "debug" ]; then
echo "Building a debug version"
qmake-qt4 glogg.pro -spec win64-x-g++ -r CONFIG+="debug win32 rtti no-dbus version_checker" BOOST_PATH=$BOOSTDIR
elif [ -z "$VERSION" ]; then
echo "Building default version"
qmake-qt4 glogg.pro -spec win64-x-g++ -r CONFIG+="release win32 rtti no-dbus version_checker" BOOST_PATH=$BOOSTDIR QMAKE_CXXFLAGS="-m64"
qmake glogg.pro -spec win64-x-g++ -r CONFIG+="release win32 rtti no-dbus version_checker" BOOST_PATH=$BOOSTDIR QMAKE_CXXFLAGS="-m64" CROSS_COMPILE="x86_64-w64-mingw32-"
else
echo "Building version $VERSION-x86_64"
qmake-qt4 glogg.pro -spec win64-x-g++ -r CONFIG+="release win32 rtti no-dbus version_checker" BOOST_PATH=$BOOSTDIR VERSION="$VERSION-x86_64"
qmake glogg.pro -spec win64-x-g++ -r CONFIG+="release win32 rtti no-dbus version_checker" BOOST_PATH=$BOOSTDIR VERSION="$VERSION-x86_64" QMAKE_CXXFLAGS="-m64" CROSS_COMPILE="x86_64-w64-mingw32-"
fi
make -j3
cp $QTXDIR/$QTVERSION/lib/{QtCore4,QtGui4,QtNetwork4}.dll release/
cp $QTXDIR/$QTVERSION/lib/{QtCored4,QtGuid4,QtNetworkd4}.dll debug/
cp $QTXDIR/$QTVERSION/bin/{Qt5Core,Qt5Gui,Qt5Network,Qt5Widgets}.dll release/
cp $QTXDIR/$QTVERSION/bin/{Qt5Core,Qt5Gui,Qt5Network,Qt5Widgets}d.dll debug/
cp /usr/x86_64-w64-mingw32/lib/libwinpthread-1.dll release/
if [ -z "$VERSION" ]; then
VERSION=`git describe`;
Expand Down
4 changes: 2 additions & 2 deletions src/abstractlogview.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -662,7 +662,7 @@ void AbstractLogView::wheelEvent( QWheelEvent* wheelEvent )
auto pixel_delta = wheelEvent->pixelDelta();

if ( pixel_delta.isNull() ) {
y_delta = wheelEvent->angleDelta().y() / 1.4;
y_delta = wheelEvent->angleDelta().y() / 0.7;
}
else {
y_delta = pixel_delta.y();
Expand Down Expand Up @@ -1453,7 +1453,7 @@ void AbstractLogView::drawTextArea( QPaintDevice* paint_device, int32_t delta_y
const int64_t lines_in_file = logData->getNbLine();

if ( firstLine > lines_in_file )
firstLine = lines_in_file - 1;
firstLine = lines_in_file ? lines_in_file - 1 : 0;

const int64_t nbLines = std::min(
static_cast<int64_t>( getNbVisibleLines() ), lines_in_file - firstLine );
Expand Down
17 changes: 11 additions & 6 deletions src/crawlerwidget.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -287,8 +287,8 @@ void CrawlerWidget::updateFilteredView( int nbMatches, int progress )
}
}

// If more matches have been found
if ( nbMatches > nbMatches_ ) {
// If more (or less, e.g. come back to 0) matches have been found
if ( nbMatches != nbMatches_ ) {
nbMatches_ = nbMatches;

// Recompute the content of the filtered window.
Expand Down Expand Up @@ -828,8 +828,6 @@ void CrawlerWidget::replaceCurrentSearch( const QString& searchText )
// Interrupt the search if it's ongoing
logFilteredData_->interruptSearch();

nbMatches_ = 0;

// We have to wait for the last search update (100%)
// before clearing/restarting to avoid having remaining results.

Expand All @@ -839,6 +837,15 @@ void CrawlerWidget::replaceCurrentSearch( const QString& searchText )
// us the overhead of having proper sync.
QApplication::processEvents( QEventLoop::ExcludeUserInputEvents );

nbMatches_ = 0;

// Clear and recompute the content of the filtered window.
logFilteredData_->clearSearch();
filteredView->updateData();

// Update the match overview
overview_.updateData( logData_->getNbLine() );

if ( !searchText.isEmpty() ) {

QString pattern;
Expand Down Expand Up @@ -900,8 +907,6 @@ void CrawlerWidget::replaceCurrentSearch( const QString& searchText )
}
}
else {
logFilteredData_->clearSearch();
filteredView->updateData();
searchState_.resetState();
printSearchInfoMessage();
}
Expand Down
Loading

0 comments on commit 39d98e3

Please sign in to comment.