forked from openkylin/quarkai
Let the child window display normal
This commit is contained in:
parent
a651459416
commit
fb42218642
|
@ -1,352 +0,0 @@
|
|||
#############################################################################
|
||||
# Makefile for building: backends
|
||||
# Generated by qmake (3.0) (Qt 5.5.1)
|
||||
# Project: backends.pro
|
||||
# Template: aux
|
||||
# Command: /usr/lib/x86_64-linux-gnu/qt5/bin/qmake -spec linux-g++-64 CONFIG+=debug -o Makefile backends.pro
|
||||
#############################################################################
|
||||
|
||||
MAKEFILE = Makefile
|
||||
|
||||
####### Compiler, tools and options
|
||||
|
||||
CC = gcc
|
||||
CXX = g++
|
||||
DEFINES =
|
||||
CFLAGS = -m64 -pipe -g -Wall -W -fPIC $(DEFINES)
|
||||
CXXFLAGS = -m64 -pipe -g -Wall -W -fPIC $(DEFINES)
|
||||
INCPATH = -I. -I/usr/lib/x86_64-linux-gnu/qt5/mkspecs/linux-g++-64
|
||||
QMAKE = /usr/lib/x86_64-linux-gnu/qt5/bin/qmake
|
||||
DEL_FILE = rm -f
|
||||
CHK_DIR_EXISTS= test -d
|
||||
MKDIR = mkdir -p
|
||||
COPY = cp -f
|
||||
COPY_FILE = cp -f
|
||||
COPY_DIR = cp -f -R
|
||||
INSTALL_FILE = install -m 644 -p
|
||||
INSTALL_PROGRAM = install -m 755 -p
|
||||
INSTALL_DIR = cp -f -R
|
||||
DEL_FILE = rm -f
|
||||
SYMLINK = ln -f -s
|
||||
DEL_DIR = rmdir
|
||||
MOVE = mv -f
|
||||
TAR = tar -cf
|
||||
COMPRESS = gzip -9f
|
||||
DISTNAME = backends1.0.0
|
||||
DISTDIR = /home/lixiang/work/kylin-assistant/backends/.tmp/backends1.0.0
|
||||
LINK = g++
|
||||
LFLAGS = -m64
|
||||
LIBS = $(SUBLIBS)
|
||||
AR = ar cqs
|
||||
RANLIB =
|
||||
SED = sed
|
||||
STRIP = strip
|
||||
|
||||
####### Output directory
|
||||
|
||||
OBJECTS_DIR = ./
|
||||
|
||||
####### Files
|
||||
|
||||
SOURCES =
|
||||
OBJECTS =
|
||||
DIST = /usr/lib/x86_64-linux-gnu/qt5/mkspecs/features/spec_pre.prf \
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/common/unix.conf \
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/common/linux.conf \
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/common/sanitize.conf \
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/common/gcc-base.conf \
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/common/gcc-base-unix.conf \
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/common/g++-base.conf \
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/common/g++-unix.conf \
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/qconfig.pri \
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/modules/qt_lib_bootstrap_private.pri \
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/modules/qt_lib_concurrent.pri \
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/modules/qt_lib_concurrent_private.pri \
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/modules/qt_lib_core.pri \
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/modules/qt_lib_core_private.pri \
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/modules/qt_lib_dbus.pri \
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/modules/qt_lib_dbus_private.pri \
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/modules/qt_lib_eglfs_device_lib_private.pri \
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/modules/qt_lib_gui.pri \
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/modules/qt_lib_gui_private.pri \
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/modules/qt_lib_multimedia.pri \
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/modules/qt_lib_multimediawidgets.pri \
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/modules/qt_lib_network.pri \
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/modules/qt_lib_network_private.pri \
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/modules/qt_lib_opengl.pri \
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/modules/qt_lib_opengl_private.pri \
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/modules/qt_lib_openglextensions.pri \
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/modules/qt_lib_openglextensions_private.pri \
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/modules/qt_lib_platformsupport_private.pri \
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/modules/qt_lib_printsupport.pri \
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/modules/qt_lib_printsupport_private.pri \
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/modules/qt_lib_script.pri \
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/modules/qt_lib_scripttools.pri \
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/modules/qt_lib_sql.pri \
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/modules/qt_lib_sql_private.pri \
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/modules/qt_lib_svg.pri \
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/modules/qt_lib_testlib.pri \
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/modules/qt_lib_testlib_private.pri \
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/modules/qt_lib_widgets.pri \
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/modules/qt_lib_widgets_private.pri \
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/modules/qt_lib_x11extras.pri \
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/modules/qt_lib_xcb_qpa_lib_private.pri \
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/modules/qt_lib_xml.pri \
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/modules/qt_lib_xml_private.pri \
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/features/qt_functions.prf \
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/features/qt_config.prf \
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/linux-g++-64/qmake.conf \
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/features/spec_post.prf \
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/features/exclusive_builds.prf \
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/features/default_pre.prf \
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/features/resolve_config.prf \
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/features/default_post.prf \
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/features/warn_on.prf \
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/features/testcase_targets.prf \
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/features/exceptions.prf \
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/features/yacc.prf \
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/features/lex.prf \
|
||||
backends.pro
|
||||
QMAKE_TARGET = backends
|
||||
DESTDIR = #avoid trailing-slash linebreak
|
||||
TARGET = backends
|
||||
TARGETA =
|
||||
TARGET0 =
|
||||
TARGETD =
|
||||
TARGET1 =
|
||||
TARGET2 =
|
||||
|
||||
|
||||
first: all
|
||||
####### Implicit rules
|
||||
|
||||
.SUFFIXES: .o .c .cpp .cc .cxx .C
|
||||
|
||||
.cpp.o:
|
||||
$(CXX) -c $(CXXFLAGS) $(INCPATH) -o "$@" "$<"
|
||||
|
||||
.cc.o:
|
||||
$(CXX) -c $(CXXFLAGS) $(INCPATH) -o "$@" "$<"
|
||||
|
||||
.cxx.o:
|
||||
$(CXX) -c $(CXXFLAGS) $(INCPATH) -o "$@" "$<"
|
||||
|
||||
.C.o:
|
||||
$(CXX) -c $(CXXFLAGS) $(INCPATH) -o "$@" "$<"
|
||||
|
||||
.c.o:
|
||||
$(CC) -c $(CFLAGS) $(INCPATH) -o "$@" "$<"
|
||||
|
||||
####### Build rules
|
||||
|
||||
$(TARGET): $(OBJECTS)
|
||||
|
||||
|
||||
Makefile: backends.pro /usr/lib/x86_64-linux-gnu/qt5/mkspecs/linux-g++-64/qmake.conf /usr/lib/x86_64-linux-gnu/qt5/mkspecs/features/spec_pre.prf \
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/common/unix.conf \
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/common/linux.conf \
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/common/sanitize.conf \
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/common/gcc-base.conf \
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/common/gcc-base-unix.conf \
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/common/g++-base.conf \
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/common/g++-unix.conf \
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/qconfig.pri \
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/modules/qt_lib_bootstrap_private.pri \
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/modules/qt_lib_concurrent.pri \
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/modules/qt_lib_concurrent_private.pri \
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/modules/qt_lib_core.pri \
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/modules/qt_lib_core_private.pri \
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/modules/qt_lib_dbus.pri \
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/modules/qt_lib_dbus_private.pri \
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/modules/qt_lib_eglfs_device_lib_private.pri \
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/modules/qt_lib_gui.pri \
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/modules/qt_lib_gui_private.pri \
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/modules/qt_lib_multimedia.pri \
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/modules/qt_lib_multimediawidgets.pri \
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/modules/qt_lib_network.pri \
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/modules/qt_lib_network_private.pri \
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/modules/qt_lib_opengl.pri \
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/modules/qt_lib_opengl_private.pri \
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/modules/qt_lib_openglextensions.pri \
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/modules/qt_lib_openglextensions_private.pri \
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/modules/qt_lib_platformsupport_private.pri \
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/modules/qt_lib_printsupport.pri \
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/modules/qt_lib_printsupport_private.pri \
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/modules/qt_lib_script.pri \
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/modules/qt_lib_scripttools.pri \
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/modules/qt_lib_sql.pri \
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/modules/qt_lib_sql_private.pri \
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/modules/qt_lib_svg.pri \
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/modules/qt_lib_testlib.pri \
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/modules/qt_lib_testlib_private.pri \
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/modules/qt_lib_widgets.pri \
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/modules/qt_lib_widgets_private.pri \
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/modules/qt_lib_x11extras.pri \
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/modules/qt_lib_xcb_qpa_lib_private.pri \
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/modules/qt_lib_xml.pri \
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/modules/qt_lib_xml_private.pri \
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/features/qt_functions.prf \
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/features/qt_config.prf \
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/linux-g++-64/qmake.conf \
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/features/spec_post.prf \
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/features/exclusive_builds.prf \
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/features/default_pre.prf \
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/features/resolve_config.prf \
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/features/default_post.prf \
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/features/warn_on.prf \
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/features/testcase_targets.prf \
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/features/exceptions.prf \
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/features/yacc.prf \
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/features/lex.prf \
|
||||
backends.pro
|
||||
$(QMAKE) -spec linux-g++-64 CONFIG+=debug -o Makefile backends.pro
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/features/spec_pre.prf:
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/common/unix.conf:
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/common/linux.conf:
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/common/sanitize.conf:
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/common/gcc-base.conf:
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/common/gcc-base-unix.conf:
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/common/g++-base.conf:
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/common/g++-unix.conf:
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/qconfig.pri:
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/modules/qt_lib_bootstrap_private.pri:
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/modules/qt_lib_concurrent.pri:
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/modules/qt_lib_concurrent_private.pri:
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/modules/qt_lib_core.pri:
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/modules/qt_lib_core_private.pri:
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/modules/qt_lib_dbus.pri:
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/modules/qt_lib_dbus_private.pri:
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/modules/qt_lib_eglfs_device_lib_private.pri:
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/modules/qt_lib_gui.pri:
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/modules/qt_lib_gui_private.pri:
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/modules/qt_lib_multimedia.pri:
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/modules/qt_lib_multimediawidgets.pri:
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/modules/qt_lib_network.pri:
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/modules/qt_lib_network_private.pri:
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/modules/qt_lib_opengl.pri:
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/modules/qt_lib_opengl_private.pri:
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/modules/qt_lib_openglextensions.pri:
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/modules/qt_lib_openglextensions_private.pri:
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/modules/qt_lib_platformsupport_private.pri:
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/modules/qt_lib_printsupport.pri:
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/modules/qt_lib_printsupport_private.pri:
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/modules/qt_lib_script.pri:
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/modules/qt_lib_scripttools.pri:
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/modules/qt_lib_sql.pri:
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/modules/qt_lib_sql_private.pri:
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/modules/qt_lib_svg.pri:
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/modules/qt_lib_testlib.pri:
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/modules/qt_lib_testlib_private.pri:
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/modules/qt_lib_widgets.pri:
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/modules/qt_lib_widgets_private.pri:
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/modules/qt_lib_x11extras.pri:
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/modules/qt_lib_xcb_qpa_lib_private.pri:
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/modules/qt_lib_xml.pri:
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/modules/qt_lib_xml_private.pri:
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/features/qt_functions.prf:
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/features/qt_config.prf:
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/linux-g++-64/qmake.conf:
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/features/spec_post.prf:
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/features/exclusive_builds.prf:
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/features/default_pre.prf:
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/features/resolve_config.prf:
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/features/default_post.prf:
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/features/warn_on.prf:
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/features/testcase_targets.prf:
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/features/exceptions.prf:
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/features/yacc.prf:
|
||||
/usr/lib/x86_64-linux-gnu/qt5/mkspecs/features/lex.prf:
|
||||
backends.pro:
|
||||
qmake: FORCE
|
||||
@$(QMAKE) -spec linux-g++-64 CONFIG+=debug -o Makefile backends.pro
|
||||
|
||||
qmake_all: FORCE
|
||||
|
||||
|
||||
all: Makefile $(TARGET)
|
||||
|
||||
dist: distdir FORCE
|
||||
(cd `dirname $(DISTDIR)` && $(TAR) $(DISTNAME).tar $(DISTNAME) && $(COMPRESS) $(DISTNAME).tar) && $(MOVE) `dirname $(DISTDIR)`/$(DISTNAME).tar.gz . && $(DEL_FILE) -r $(DISTDIR)
|
||||
|
||||
distdir: FORCE
|
||||
@test -d $(DISTDIR) || mkdir -p $(DISTDIR)
|
||||
$(COPY_FILE) --parents $(DIST) $(DISTDIR)/
|
||||
|
||||
|
||||
clean: compiler_clean
|
||||
-$(DEL_FILE) *~ core *.core
|
||||
|
||||
|
||||
distclean: clean
|
||||
-$(DEL_FILE) $(TARGET)
|
||||
-$(DEL_FILE) $(TARGET0) $(TARGET1) $(TARGET2) $(TARGETA)
|
||||
-$(DEL_FILE) Makefile
|
||||
|
||||
|
||||
####### Sub-libraries
|
||||
|
||||
check: first
|
||||
|
||||
compiler_yacc_decl_make_all:
|
||||
compiler_yacc_decl_clean:
|
||||
compiler_yacc_impl_make_all:
|
||||
compiler_yacc_impl_clean:
|
||||
compiler_lex_make_all:
|
||||
compiler_lex_clean:
|
||||
compiler_clean:
|
||||
|
||||
####### Compile
|
||||
|
||||
####### Install
|
||||
|
||||
install_inst1: first FORCE
|
||||
@test -d $(INSTALL_ROOT)/usr/lib/python2.7/dist-packages/kylin-assistant-daemon/ || mkdir -p $(INSTALL_ROOT)/usr/lib/python2.7/dist-packages/kylin-assistant-daemon/
|
||||
-$(INSTALL_DIR) /home/lixiang/work/kylin-assistant/backends/kylin-assistant-daemon/src $(INSTALL_ROOT)/usr/lib/python2.7/dist-packages/kylin-assistant-daemon/
|
||||
|
||||
uninstall_inst1: FORCE
|
||||
-$(DEL_FILE) -r $(INSTALL_ROOT)/usr/lib/python2.7/dist-packages/kylin-assistant-daemon/src
|
||||
-$(DEL_DIR) $(INSTALL_ROOT)/usr/lib/python2.7/dist-packages/kylin-assistant-daemon/
|
||||
|
||||
|
||||
install_inst2: first FORCE
|
||||
@test -d $(INSTALL_ROOT)/var/lib/kylin-assistant-daemon/ || mkdir -p $(INSTALL_ROOT)/var/lib/kylin-assistant-daemon/
|
||||
-$(INSTALL_DIR) /home/lixiang/work/kylin-assistant/backends/kylin-assistant-daemon/data/beautify/autostart $(INSTALL_ROOT)/var/lib/kylin-assistant-daemon/
|
||||
|
||||
uninstall_inst2: FORCE
|
||||
-$(DEL_FILE) -r $(INSTALL_ROOT)/var/lib/kylin-assistant-daemon/autostart
|
||||
-$(DEL_DIR) $(INSTALL_ROOT)/var/lib/kylin-assistant-daemon/
|
||||
|
||||
|
||||
install_inst3: first FORCE
|
||||
@test -d $(INSTALL_ROOT)/var/lib/kylin-assistant-daemon/ || mkdir -p $(INSTALL_ROOT)/var/lib/kylin-assistant-daemon/
|
||||
-$(INSTALL_DIR) /home/lixiang/work/kylin-assistant/backends/kylin-assistant-daemon/data/beautify/plymouth $(INSTALL_ROOT)/var/lib/kylin-assistant-daemon/
|
||||
|
||||
uninstall_inst3: FORCE
|
||||
-$(DEL_FILE) -r $(INSTALL_ROOT)/var/lib/kylin-assistant-daemon/plymouth
|
||||
-$(DEL_DIR) $(INSTALL_ROOT)/var/lib/kylin-assistant-daemon/
|
||||
|
||||
|
||||
install_inst4: first FORCE
|
||||
@test -d $(INSTALL_ROOT)/var/lib/kylin-assistant-daemon/ || mkdir -p $(INSTALL_ROOT)/var/lib/kylin-assistant-daemon/
|
||||
-$(INSTALL_DIR) /home/lixiang/work/kylin-assistant/backends/kylin-assistant-daemon/data/beautify/sound-theme $(INSTALL_ROOT)/var/lib/kylin-assistant-daemon/
|
||||
|
||||
uninstall_inst4: FORCE
|
||||
-$(DEL_FILE) -r $(INSTALL_ROOT)/var/lib/kylin-assistant-daemon/sound-theme
|
||||
-$(DEL_DIR) $(INSTALL_ROOT)/var/lib/kylin-assistant-daemon/
|
||||
|
||||
|
||||
install_inst5: first FORCE
|
||||
@test -d $(INSTALL_ROOT)/var/lib/kylin-assistant-daemon/ || mkdir -p $(INSTALL_ROOT)/var/lib/kylin-assistant-daemon/
|
||||
-$(INSTALL_FILE) /home/lixiang/work/kylin-assistant/backends/kylin-assistant-daemon/data/ubuntukylin-default-settings.ini $(INSTALL_ROOT)/var/lib/kylin-assistant-daemon/
|
||||
|
||||
uninstall_inst5: FORCE
|
||||
-$(DEL_FILE) -r $(INSTALL_ROOT)/var/lib/kylin-assistant-daemon/ubuntukylin-default-settings.ini
|
||||
-$(DEL_DIR) $(INSTALL_ROOT)/var/lib/kylin-assistant-daemon/
|
||||
|
||||
|
||||
install: install_inst1 install_inst2 install_inst3 install_inst4 install_inst5 FORCE
|
||||
|
||||
uninstall: uninstall_inst1 uninstall_inst2 uninstall_inst3 uninstall_inst4 uninstall_inst5 FORCE
|
||||
|
||||
FORCE:
|
||||
|
|
@ -20,8 +20,6 @@
|
|||
#include "cleaneritems.h"
|
||||
#include "mainwindow.h"
|
||||
#include <QDebug>
|
||||
#include <QCheckBox>
|
||||
#include <QGroupBox>
|
||||
|
||||
//CleanerItems::CleanerItems(QStringList &arglist, QStringList &statuslist, int height, const QString title_text, QWidget *parent)
|
||||
// : QWidget(parent),titleName(title_text)/*, widgetHeight(height)*/
|
||||
|
|
|
@ -22,6 +22,8 @@
|
|||
|
||||
#include <QWidget>
|
||||
#include <QDialog>
|
||||
#include <QCheckBox>
|
||||
#include <QGroupBox>
|
||||
#include "../component/kylintitlebar.h"
|
||||
|
||||
class MainWindow;
|
||||
|
|
|
@ -17,6 +17,9 @@
|
|||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*/
|
||||
|
||||
|
||||
//#pragma once
|
||||
|
||||
#ifndef AGENTLISTITEM_H
|
||||
#define AGENTLISTITEM_H
|
||||
|
||||
|
|
|
@ -236,7 +236,7 @@ void KylinMenu::forumHelp()
|
|||
void KylinMenu::questionFeedback()
|
||||
{
|
||||
this->close();
|
||||
QUrl url(QString("https://bugs.launchpad.net/kylin-assistant"));
|
||||
QUrl url(QString("https://bugs.launchpad.net/youker-assistant"));
|
||||
QDesktopServices::openUrl(url);
|
||||
}
|
||||
|
||||
|
|
|
@ -32,6 +32,7 @@ public:
|
|||
virtual QString getDescribe() = 0;
|
||||
virtual QString getPicture() = 0;
|
||||
virtual void doAction() = 0;
|
||||
virtual QWidget *centralWidget() = 0;
|
||||
};
|
||||
|
||||
//Q_DECLARE_INTERFACE定义在在qobject.h中,用来告诉Qt meta-object system 这个接口名称
|
||||
|
|
|
@ -15,7 +15,6 @@
|
|||
*/
|
||||
|
||||
#include "toolkits.h"
|
||||
#include <QGraphicsOpacityEffect>
|
||||
|
||||
Toolkits::Toolkits(QObject *parent, int width, int height) :
|
||||
QObject(parent), parent_width(width), parent_height(height)
|
||||
|
|
|
@ -19,10 +19,9 @@
|
|||
#include <QObject>
|
||||
#include <QtGui>
|
||||
#include <QDebug>
|
||||
#include <QGraphicsOpacityEffect>
|
||||
#include "alertdialog.h"
|
||||
|
||||
class QGraphicsOpacityEffect;
|
||||
|
||||
class Toolkits : public QObject
|
||||
{
|
||||
Q_OBJECT
|
||||
|
|
|
@ -28,6 +28,8 @@
|
|||
#define PAGESPACE 20
|
||||
#define ITEMWIDTH 650
|
||||
|
||||
//#define VERSION "2.4.1"
|
||||
|
||||
const QString KYLIN_COMPANY_SETTING = "kylin/kylin-assistant";
|
||||
const QString KYLIN_SETTING_FILE_NAME_SETTING = "kylin-assistant";
|
||||
|
||||
|
|
|
@ -1,7 +1,8 @@
|
|||
kylin-assistant (1.0.0-0ubuntu1) bionic; urgency=low
|
||||
|
||||
* fork youker-assistant(commit:764)
|
||||
* upgrade from Qt4 to Qt5.
|
||||
* add qtsingleapplication.
|
||||
* Fork youker-assistant(commit:764)
|
||||
* Upgrade from Qt4 to Qt5.
|
||||
* Add qtsingleapplication.
|
||||
* Let the child window display normal.
|
||||
|
||||
-- lixiang <lixiang@kylinos.cn> Thu, 21 Dec 2017 14:52:56 +0800
|
||||
|
|
|
@ -31,8 +31,10 @@
|
|||
//pkg-config --cflags libgtop-2.0
|
||||
//pkg-config --libs glib-2.0 libgtop-2.0
|
||||
|
||||
ProcessDialog::ProcessDialog(ProcessManager *plugin, QDialog *parent)
|
||||
:QDialog(parent)
|
||||
//ProcessDialog::ProcessDialog(ProcessManager *plugin, QDialog *parent)
|
||||
//:QDialog(parent)
|
||||
ProcessDialog::ProcessDialog(QWidget *parent)
|
||||
:QWidget(parent)
|
||||
{
|
||||
setWindowFlags(Qt::FramelessWindowHint);
|
||||
this->setStyleSheet("QDialog{border: 1px solid white;border-radius:1px;background-color: #ffffff;}");
|
||||
|
@ -44,8 +46,8 @@ ProcessDialog::ProcessDialog(ProcessManager *plugin, QDialog *parent)
|
|||
|
||||
initTitleBar();
|
||||
|
||||
this->setFixedSize(850, 476);
|
||||
process_plugin = plugin;
|
||||
// this->setFixedSize(850, 476);
|
||||
// process_plugin = plugin;
|
||||
|
||||
toolkits = new Toolkits(0, this->width(), this->height());
|
||||
tip_label = new QLabel();
|
||||
|
|
|
@ -39,19 +39,22 @@
|
|||
|
||||
class ProcessManager;
|
||||
|
||||
class ProcessDialog : public QDialog
|
||||
//class ProcessDialog : public QDialog
|
||||
class ProcessDialog : public QWidget
|
||||
{
|
||||
Q_OBJECT
|
||||
public:
|
||||
ProcessDialog(ProcessManager *plugin, QDialog *parent = 0);
|
||||
~ProcessDialog();
|
||||
void setLanguage();
|
||||
void initConnect();
|
||||
void initTitleBar();
|
||||
void showProList();
|
||||
QString getCurrrentSkinName();
|
||||
void resetSkin();
|
||||
ProcApp *app;
|
||||
// ProcessDialog(ProcessManager *plugin, QDialog *parent = 0);
|
||||
explicit ProcessDialog(QWidget* parent = 0);
|
||||
~ProcessDialog();
|
||||
|
||||
void setLanguage();
|
||||
void initConnect();
|
||||
void initTitleBar();
|
||||
void showProList();
|
||||
QString getCurrrentSkinName();
|
||||
void resetSkin();
|
||||
ProcApp *app;
|
||||
|
||||
protected:
|
||||
void closeEvent(QCloseEvent *event);
|
||||
|
@ -64,7 +67,7 @@ private slots:
|
|||
// void onMinButtonClicked();
|
||||
|
||||
private:
|
||||
ProcessManager *process_plugin;
|
||||
// ProcessManager *process_plugin;
|
||||
QLabel *tip_label;
|
||||
QPushButton *kill_btn;
|
||||
QTableWidget *tableWidget;
|
||||
|
|
|
@ -21,15 +21,31 @@
|
|||
#include <QDebug>
|
||||
#include <QApplication>
|
||||
#include <QDesktopWidget>
|
||||
#include <QStackedLayout>
|
||||
|
||||
//ProcessManager::ProcessManager(QObject *parent)
|
||||
//:QObject(parent), process_dialog(this)
|
||||
ProcessManager::ProcessManager(QObject *parent)
|
||||
:QObject(parent), process_dialog(this)
|
||||
: QObject(parent)
|
||||
// ,m_view(new QFrame)
|
||||
{
|
||||
/*ProcessDialog *process_dialog = new ProcessDialog;
|
||||
QStackedLayout *layout = new QStackedLayout;
|
||||
layout->setSpacing(0);
|
||||
layout->setMargin(0);
|
||||
|
||||
layout->addWidget(process_dialog);
|
||||
|
||||
m_view->setLayout(layout);*/
|
||||
process_dialog = new ProcessDialog;
|
||||
}
|
||||
|
||||
ProcessManager::~ProcessManager()
|
||||
{
|
||||
if (process_dialog) {
|
||||
delete process_dialog;
|
||||
process_dialog = nullptr;
|
||||
}
|
||||
}
|
||||
|
||||
QString ProcessManager::getGuid()
|
||||
|
@ -52,16 +68,24 @@ QString ProcessManager::getPicture()
|
|||
return "processmanager.png";
|
||||
}
|
||||
|
||||
void ProcessManager::doAction()
|
||||
void ProcessManager::doAction()
|
||||
{
|
||||
int windowWidth = QApplication::desktop()->width();
|
||||
int windowHeight = QApplication::desktop()->height();
|
||||
process_dialog.resetSkin();
|
||||
process_dialog.move((windowWidth - 850) / 2,(windowHeight - 476) / 2);
|
||||
process_dialog.show();
|
||||
process_dialog.raise();
|
||||
process_dialog->resetSkin();
|
||||
process_dialog->move((windowWidth - 850) / 2,(windowHeight - 476) / 2);
|
||||
process_dialog->show();
|
||||
process_dialog->raise();
|
||||
|
||||
}
|
||||
|
||||
QWidget *ProcessManager::centralWidget()
|
||||
{
|
||||
// return m_view;
|
||||
return process_dialog;
|
||||
}
|
||||
|
||||
|
||||
#if QT_VERSION < QT_VERSION_CHECK(5, 0, 0)
|
||||
Q_EXPORT_PLUGIN2(ProcessManager, ProcessManager)
|
||||
#endif
|
||||
|
|
|
@ -33,8 +33,9 @@ class ProcessManager : public QObject , PluginInterface
|
|||
#endif
|
||||
|
||||
public:
|
||||
ProcessManager(QObject* parent = 0);
|
||||
explicit ProcessManager(QObject* parent = 0);
|
||||
virtual ~ProcessManager();
|
||||
QWidget *centralWidget();
|
||||
|
||||
public slots:
|
||||
|
||||
|
@ -46,5 +47,6 @@ public:
|
|||
virtual void doAction();
|
||||
|
||||
private:
|
||||
ProcessDialog process_dialog;
|
||||
ProcessDialog *process_dialog = nullptr;
|
||||
// QWidget *m_view;
|
||||
};
|
||||
|
|
|
@ -56,5 +56,8 @@ SOURCES += \
|
|||
FORMS += \
|
||||
../component/alertdialog.ui
|
||||
|
||||
OTHER_FILES += \
|
||||
process.json
|
||||
|
||||
RESOURCES += \
|
||||
../src/img.qrc
|
||||
|
|
|
@ -19,8 +19,6 @@
|
|||
|
||||
#include "fontwidget.h"
|
||||
#include <QDebug>
|
||||
#include <QDoubleSpinBox>
|
||||
#include <QComboBox>
|
||||
#include "../component/kylinfontdialog.h"
|
||||
#include "../dbusproxy/youkersessiondbus.h"
|
||||
#include "../src/mainwindow.h"
|
||||
|
|
|
@ -21,6 +21,8 @@
|
|||
#define FONTWIDGET_H
|
||||
|
||||
#include <QWidget>
|
||||
#include <QDoubleSpinBox>
|
||||
#include <QComboBox>
|
||||
|
||||
class SessionDispatcher;
|
||||
class MainWindow;
|
||||
|
|
|
@ -17,10 +17,13 @@
|
|||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*/
|
||||
|
||||
#include "shreddialog.h"
|
||||
#include "filewipe.h"
|
||||
//#include "shredmanager.h"
|
||||
|
||||
#include <QStringList>
|
||||
#include <QCloseEvent>
|
||||
#include <QBitmap>
|
||||
#include "shredmanager.h"
|
||||
#include <QFileDialog>
|
||||
#include <QDir>
|
||||
#include <QVBoxLayout>
|
||||
|
@ -30,16 +33,17 @@
|
|||
#include <QPushButton>
|
||||
#include <QComboBox>
|
||||
#include <QDebug>
|
||||
#include "filewipe.h"
|
||||
|
||||
ShredDialog::ShredDialog(ShredManager *plugin, QDialog *parent)
|
||||
:QDialog(parent)
|
||||
//ShredDialog::ShredDialog(ShredManager *plugin, QDialog *parent)
|
||||
// :QDialog(parent)
|
||||
ShredDialog::ShredDialog(QWidget *parent) :
|
||||
QWidget(parent)
|
||||
{
|
||||
setWindowFlags(Qt::FramelessWindowHint);
|
||||
this->setStyleSheet("QDialog{border: 1px solid white;border-radius:1px;background-color: #ffffff;}");
|
||||
this->setWindowIcon(QIcon(":/res/kylin-assistant.png"));
|
||||
this->setFixedSize(500, 471);
|
||||
process_plugin = plugin;
|
||||
// process_plugin = plugin;
|
||||
|
||||
shredSettings = new QSettings(KYLIN_COMPANY_SETTING, KYLIN_SETTING_FILE_NAME_SETTING);
|
||||
shredSettings->setIniCodec("UTF-8");
|
||||
|
@ -206,8 +210,8 @@ void ShredDialog::onSelectButtonClicked()
|
|||
QFileDialog* fd = new QFileDialog(this);
|
||||
// fd->setStyleSheet("QFileDialog{background-color:blue;}");
|
||||
fd->resize(500, 471);
|
||||
fd->setFilter(QDir::Files | QDir::NoSymLinks | QDir::NoDotAndDotDot);
|
||||
// fd->setFilter(tr("Allfile(*)"));
|
||||
fd->setFilter(QDir::Files | QDir::NoSymLinks | QDir::NoDotAndDotDot);
|
||||
// fd->setFilter( "Allfile(*.*);;mp3file(*.mp3);;wmafile(*.wma);;wavefile(*.wav)");
|
||||
fd->setViewMode(QFileDialog::List);//设置浏览模式,有 列表(list) 模式和 详细信息(detail)两种方式
|
||||
if (fd->exec() == QDialog::Accepted)
|
||||
|
|
|
@ -28,13 +28,15 @@ class QLabel;
|
|||
class QPushButton;
|
||||
class QLineEdit;
|
||||
class QComboBox;
|
||||
class ShredManager;
|
||||
//class ShredManager;
|
||||
|
||||
class ShredDialog : public QDialog
|
||||
class ShredDialog : public QWidget
|
||||
//class ShredDialog : public QDialog
|
||||
{
|
||||
Q_OBJECT
|
||||
public:
|
||||
ShredDialog(ShredManager *plugin, QDialog *parent = 0);
|
||||
// ShredDialog(ShredManager *plugin, QDialog *parent = 0);
|
||||
explicit ShredDialog(QWidget *parent = 0);
|
||||
~ShredDialog();
|
||||
void setLanguage();
|
||||
void initConnect();
|
||||
|
@ -54,7 +56,7 @@ public slots:
|
|||
// void onMinButtonClicked();
|
||||
|
||||
private:
|
||||
ShredManager *process_plugin;
|
||||
// ShredManager *process_plugin;
|
||||
KylinTitleBar *title_bar;
|
||||
KylinEditButton *select_btn;
|
||||
QLineEdit *select_edit;
|
||||
|
|
|
@ -20,18 +20,24 @@
|
|||
#include "shredmanager.h"
|
||||
#include <QApplication>
|
||||
#include <QDesktopWidget>
|
||||
#include <sys/types.h>
|
||||
#include <unistd.h>
|
||||
|
||||
//ShredManager::ShredManager(QObject *parent)
|
||||
//:QObject(parent), shred_dialog(this)
|
||||
//{
|
||||
|
||||
//}
|
||||
ShredManager::ShredManager(QObject *parent)
|
||||
:QObject(parent), shred_dialog(this)
|
||||
: QObject(parent)
|
||||
{
|
||||
|
||||
shred_dialog = new ShredDialog;
|
||||
}
|
||||
|
||||
ShredManager::~ShredManager()
|
||||
{
|
||||
|
||||
if (shred_dialog) {
|
||||
delete shred_dialog;
|
||||
shred_dialog = nullptr;
|
||||
}
|
||||
}
|
||||
|
||||
QString ShredManager::getGuid()
|
||||
|
@ -58,10 +64,15 @@ void ShredManager::doAction()
|
|||
{
|
||||
int windowWidth = QApplication::desktop()->width();
|
||||
int windowHeight = QApplication::desktop()->height();
|
||||
shred_dialog.resetSkin();
|
||||
shred_dialog.move((windowWidth - 500) / 2,(windowHeight - 471) / 2);
|
||||
shred_dialog.show();
|
||||
shred_dialog.raise();
|
||||
shred_dialog->resetSkin();
|
||||
shred_dialog->move((windowWidth - 500) / 2,(windowHeight - 471) / 2);
|
||||
shred_dialog->show();
|
||||
shred_dialog->raise();
|
||||
}
|
||||
|
||||
QWidget *ShredManager::centralWidget()
|
||||
{
|
||||
return shred_dialog;
|
||||
}
|
||||
|
||||
#if QT_VERSION < QT_VERSION_CHECK(5, 0, 0)
|
||||
|
|
|
@ -27,15 +27,14 @@ class ShredManager : public QObject , PluginInterface
|
|||
{
|
||||
Q_OBJECT
|
||||
Q_INTERFACES(PluginInterface)
|
||||
|
||||
#if QT_VERSION >= QT_VERSION_CHECK(5, 0, 0)
|
||||
Q_PLUGIN_METADATA(IID "com.ubuntukylin.Plugin.PluginInterface" FILE "shred.json")//指定IID和.json文件
|
||||
#endif
|
||||
|
||||
|
||||
public:
|
||||
ShredManager(QObject* parent = 0);
|
||||
explicit ShredManager(QObject* parent = 0);
|
||||
virtual ~ShredManager();
|
||||
QWidget *centralWidget();
|
||||
|
||||
public slots:
|
||||
|
||||
|
@ -47,5 +46,5 @@ public:
|
|||
virtual void doAction();
|
||||
|
||||
private:
|
||||
ShredDialog shred_dialog;
|
||||
ShredDialog *shred_dialog = nullptr;
|
||||
};
|
||||
|
|
|
@ -4,13 +4,15 @@
|
|||
#
|
||||
#-------------------------------------------------
|
||||
|
||||
QT += core
|
||||
isEqual(QT_MAJOR_VERSION, 5) {
|
||||
QT += widgets gui
|
||||
}
|
||||
#greaterThan(QT_MAJOR_VERSION, 4): QT += widgets
|
||||
|
||||
TARGET = shredmanager
|
||||
TEMPLATE = lib
|
||||
CONFIG += plugin
|
||||
CONFIG += plugin c++11
|
||||
INCLUDEPATH += ../shredmanager
|
||||
DESTDIR = ../libs
|
||||
|
||||
|
|
|
@ -72,18 +72,18 @@ AboutDialog::AboutDialog(QWidget *parent, /*const QString &version, */QString sk
|
|||
nameLabel->setAlignment(Qt::AlignCenter);
|
||||
// if (arch == "aarch64" || os == "Kylin" || os == "YHKylin") {//20161228
|
||||
// close_btn->move(442-36, 0);
|
||||
// nameLabel->setText(tr("Kylin Assisant") + " " + qApp->applicationVersion());
|
||||
// nameLabel->setText(tr("Kylin Assisant") + " " + VERSION);
|
||||
// }
|
||||
// else {
|
||||
// close_btn->move(0, 0);
|
||||
// nameLabel->setText(tr("Kylin Assisant") + " " + qApp->applicationVersion());
|
||||
// nameLabel->setText(tr("Youker Assisant") + " " + VERSION);
|
||||
// }
|
||||
|
||||
close_btn->move(442-36, 0);
|
||||
nameLabel->setText(tr("Kylin Assistant") + " " + qApp->applicationVersion());
|
||||
|
||||
// linkLabel->setAlignment(Qt::AlignRight);
|
||||
// linkLabel->setText(QString::fromLocal8Bit("<a style='color: green;' href = https://launchpad.net/kylin-assistant> home page</a>"));
|
||||
// linkLabel->setText(QString::fromLocal8Bit("<a style='color: green;' href = https://launchpad.net/youker-assistant> home page</a>"));
|
||||
|
||||
aboutBtn = new QPushButton(baseWidget);
|
||||
aboutBtn->setText(tr("About"));
|
||||
|
@ -119,7 +119,7 @@ AboutDialog::AboutDialog(QWidget *parent, /*const QString &version, */QString sk
|
|||
// }
|
||||
// else {
|
||||
// contributorEdit->setText(tr("Maintainer:\nUbuntu Kylin Team <ubuntukylin-members@list.launchpad.net>"));
|
||||
// aboutEdit->append(tr(" Kylin Assistant is a powerful system supporting software which is developed by Ubuntu Kylin team. Mainly for the naive user, it can help users manage the system. At present, It provides system junk scanning and cleaning, viewing the system hardware and software information, system customization, task manager, and some other functions."));
|
||||
// aboutEdit->append(tr(" Youker Assistant is a powerful system supporting software which is developed by Ubuntu Kylin team. Mainly for the naive user, it can help users manage the system. At present, It provides system junk scanning and cleaning, viewing the system hardware and software information, system customization, task manager, and some other functions."));
|
||||
// aboutEdit->append(tr(" The software is still under development. Please visit ") + QString::fromLocal8Bit("<a style='color: #3f96e4;' href = http://www.ubuntukylin.com>www.ubuntukylin.com</a>") + tr(" for more information. Welcome everyone to join with us. youker-assistant Homepage: "));
|
||||
// }
|
||||
|
||||
|
@ -127,7 +127,7 @@ AboutDialog::AboutDialog(QWidget *parent, /*const QString &version, */QString sk
|
|||
aboutEdit->append(tr(" Kylin Assistant is a powerful system supporting software which is developed by Kylin team. Mainly for the naive user, it can help users manage the system. At present, It provides system junk scanning and cleaning, viewing the system hardware and software information, task manager, and some other functions."));
|
||||
aboutEdit->append(tr(" The software is still under development. Please visit ") + QString::fromLocal8Bit("<a style='color: #3f96e4;' href = http://www.ubuntukylin.com>www.ubuntukylin.com</a>") + tr(" for more information. Welcome everyone to join with us. kylin-assistant Homepage: "));
|
||||
|
||||
aboutEdit->append(QString::fromLocal8Bit("<a style='color: #3f96e4;' href=\"https://launchpad.net/kylin-assistant\">https://launchpad.net/kylin-assistant</a>"));
|
||||
aboutEdit->append(QString::fromLocal8Bit("<a style='color: #3f96e4;' href=\"https://launchpad.net/youker-assistant\">https://launchpad.net/youker-assistant</a>"));
|
||||
|
||||
contributorEdit->hide();
|
||||
|
||||
|
|
|
@ -22,10 +22,13 @@
|
|||
#include "../component/plugininterface.h"
|
||||
#include "pluginmanager.h"
|
||||
#include <QGridLayout>
|
||||
#include <QStackedLayout>
|
||||
#include "../dbusproxy/youkersessiondbus.h"
|
||||
|
||||
BoxWidget::BoxWidget(QWidget *parent, QString arch, QString os, QString path) :
|
||||
QWidget(parent), osarch(arch), osname(os), plugin_path(path)
|
||||
// ,m_pluginsLayout(new QStackedLayout)
|
||||
// ,m_pluginsManager(new PluginManager(this))
|
||||
{
|
||||
this->setFixedSize(900, 403);
|
||||
this->setStyleSheet("QWidget{border: none;}");
|
||||
|
@ -64,12 +67,41 @@ BoxWidget::BoxWidget(QWidget *parent, QString arch, QString os, QString path) :
|
|||
layout->setMargin(0);
|
||||
layout->setContentsMargins(0, 0, 0, 0);
|
||||
setLayout(layout);
|
||||
|
||||
|
||||
|
||||
/*m_pluginLayoutWidget = new QWidget;
|
||||
m_pluginLayoutWidget->setLayout(m_pluginsLayout);
|
||||
QVBoxLayout *pluginWidgetLayout = new QVBoxLayout;
|
||||
pluginWidgetLayout->addWidget(m_pluginLayoutWidget);
|
||||
pluginWidgetLayout->setSpacing(0);
|
||||
pluginWidgetLayout->setMargin(0);
|
||||
m_pluginWidget = new QWidget;
|
||||
m_pluginWidget->setLayout(pluginWidgetLayout);
|
||||
|
||||
QVBoxLayout *centralLayout = new QVBoxLayout(this);
|
||||
centralLayout->addWidget(list_view);
|
||||
centralLayout->addWidget(m_pluginWidget);
|
||||
centralLayout->setSpacing(0);
|
||||
centralLayout->setMargin(0);
|
||||
|
||||
connect(m_pluginsManager, &PluginManager::pluginAdded, this, &BoxWidget::pluginAdded, Qt::QueuedConnection);
|
||||
m_pluginsManager->loadPlugin(plugin_path);*/
|
||||
}
|
||||
|
||||
BoxWidget::~BoxWidget()
|
||||
{
|
||||
}
|
||||
|
||||
//void BoxWidget::pluginAdded(QWidget * const w)
|
||||
//{
|
||||
// qDebug() << "BoxWidget::pluginAdded............";
|
||||
// w->setSizePolicy(QSizePolicy::Expanding, QSizePolicy::Expanding);
|
||||
// const int idx = m_pluginsLayout->addWidget(w);
|
||||
// m_pluginsLayout->setCurrentIndex(idx);
|
||||
//}
|
||||
|
||||
|
||||
void BoxWidget::displayBoxHomePage() {
|
||||
// stacked_widget->setCurrentIndex(0);
|
||||
}
|
||||
|
|
|
@ -29,6 +29,8 @@
|
|||
//#include "../component/kylinlistview.h"
|
||||
|
||||
class SessionDispatcher;
|
||||
class PluginManager;
|
||||
class QStackedLayout;
|
||||
|
||||
class BoxWidget : public QWidget
|
||||
{
|
||||
|
@ -48,6 +50,8 @@ public slots:
|
|||
void displayBoxHomePage();
|
||||
void displayBoxSubPage(QString plugin_id);
|
||||
|
||||
// void pluginAdded(QWidget * const w);
|
||||
|
||||
private:
|
||||
QListView *list_view;
|
||||
// KylinListView *list_view;
|
||||
|
@ -56,6 +60,11 @@ private:
|
|||
QString osarch;
|
||||
QString plugin_path;
|
||||
SessionDispatcher *sessionProxy;
|
||||
|
||||
// PluginManager *m_pluginsManager = nullptr;
|
||||
// QStackedLayout *m_pluginsLayout;
|
||||
// QWidget *m_pluginLayoutWidget;
|
||||
// QWidget *m_pluginWidget;
|
||||
};
|
||||
|
||||
#endif // BOXWIDGET_H
|
||||
|
|
|
@ -43,6 +43,7 @@ HomePage::HomePage(QWidget *parent, QString arch, QString os/*, const QString &v
|
|||
// QPixmap pixmap("://res/scan.png");
|
||||
// scan_button->setIcon(pixmap);
|
||||
// scan_button->setIconSize(pixmap.size());
|
||||
current_version = qApp->applicationVersion();
|
||||
version_logo = new QLabel();
|
||||
version_title = new QLabel();
|
||||
version_tip = new QLabel();
|
||||
|
@ -255,7 +256,7 @@ void HomePage::initConnect()
|
|||
|
||||
void HomePage::setLanguage()
|
||||
{
|
||||
version_title->setText(tr("Current Version Number") + " " + qApp->applicationVersion());
|
||||
version_title->setText(tr("Current Version Number") + " " + current_version);
|
||||
version_tip->setText(tr("Update to the lastest version, make it work better"));
|
||||
check_btn->setText(tr("updating on the backend"));
|
||||
box_title->setText(tr("Common toolbox"));
|
||||
|
|
|
@ -79,6 +79,7 @@ private:
|
|||
MainWindow *p_mainwindow;
|
||||
// AutoStartWidget *auto_start;
|
||||
// CameraManager *camera_manager;
|
||||
QString current_version;
|
||||
QString osname;
|
||||
QString osarch;
|
||||
QList<ToolButton *> item_list;
|
||||
|
|
|
@ -24,13 +24,18 @@
|
|||
#include <QDesktopWidget>
|
||||
#include <QGraphicsDropShadowEffect>
|
||||
#include "shadowwidget.h"
|
||||
#include "../component/utils.h"
|
||||
//#include "cameramanager.h"
|
||||
#include "../component/threadpool.h"
|
||||
|
||||
QString GlobalData::globalarch = ""; // add by hebing, just for transmit var
|
||||
|
||||
MainWindow::MainWindow(QString cur_arch, int d_count, QWidget *parent) :
|
||||
QDialog(parent), arch(cur_arch), display_count(d_count)/*skin_center(parent),*/
|
||||
//MainWindow::MainWindow(QString cur_arch, int d_count, QWidget *parent) :
|
||||
// QDialog(parent), arch(cur_arch), display_count(d_count)/*skin_center(parent),*/
|
||||
MainWindow::MainWindow(QString cur_arch, int d_count, QWidget* parent, Qt::WindowFlags flags)
|
||||
: QMainWindow( parent, flags )
|
||||
,arch(cur_arch)
|
||||
,display_count(d_count)
|
||||
{
|
||||
|
||||
GlobalData::globalarch = this->arch;
|
||||
|
@ -48,7 +53,7 @@ MainWindow::MainWindow(QString cur_arch, int d_count, QWidget *parent) :
|
|||
|
||||
// this->osName = "Kylin";
|
||||
// if (this->arch == "aarch64" || this->osName == "Kylin" || this->osName == "YHKylin") {
|
||||
if (this->desktop == "MATE" || this->desktop == "mate" || this->desktop == "UKUI" || this->desktop == "ukui") {
|
||||
/*if (this->desktop == "MATE" || this->desktop == "mate" || this->desktop == "UKUI" || this->desktop == "ukui") {
|
||||
this->isTopLevel();
|
||||
this->resize(900, 600);
|
||||
this->setAutoFillBackground(true);
|
||||
|
@ -59,12 +64,19 @@ MainWindow::MainWindow(QString cur_arch, int d_count, QWidget *parent) :
|
|||
this->setFixedSize(900, 600);
|
||||
this->setWindowFlags(Qt::FramelessWindowHint | Qt::WindowMinimizeButtonHint | Qt::WindowSystemMenuHint);
|
||||
this->setWindowTitle(tr("Kylin Assistant"));
|
||||
}
|
||||
}*/
|
||||
|
||||
this->setWindowTitle(tr("Kylin Assistant"));
|
||||
this->setMouseTracking(true);
|
||||
this->setAutoFillBackground(true);
|
||||
QWidget::setWindowFlags(Qt::Window | Qt::FramelessWindowHint);
|
||||
this->setMinimumSize(900, 600);
|
||||
this->resize(900, 600);
|
||||
|
||||
// this->setWindowFlags(Qt::FramelessWindowHint | Qt::WindowMinimizeButtonHint | Qt::WindowSystemMenuHint);
|
||||
//// this->setAttribute(Qt::WA_TranslucentBackground, true);
|
||||
|
||||
this->setWindowIcon(QIcon(":/res/v-assistant.png"));
|
||||
this->setWindowIcon(QIcon(":/res/kylin-assistant.png"));
|
||||
this->setWindowOpacity(1);
|
||||
// this->setWindowFlags(Qt::FramelessWindowHint | Qt::Widget);
|
||||
// this->setAttribute(Qt::WA_TranslucentBackground);
|
||||
|
@ -74,19 +86,12 @@ MainWindow::MainWindow(QString cur_arch, int d_count, QWidget *parent) :
|
|||
status = HOMEPAGE;
|
||||
statusFlag = false;
|
||||
|
||||
|
||||
|
||||
// this->setWindowFlags(Qt::FramelessWindowHint);
|
||||
this->setAttribute(Qt::WA_TranslucentBackground);
|
||||
this->setAttribute(Qt::WA_ShowModal);
|
||||
|
||||
/*QGraphicsDropShadowEffect *shadow_effect = new QGraphicsDropShadowEffect(this);
|
||||
shadow_effect->setBlurRadius(15.0);
|
||||
shadow_effect->setColor(QColor(0, 0, 0, 100));//shadow_effect->setColor(Qt::gray);
|
||||
shadow_effect->setOffset(1.0);//shadow_effect->setOffset(-5, 5);
|
||||
this->setGraphicsEffect(shadow_effect);*/
|
||||
|
||||
|
||||
sessioninterface = NULL;
|
||||
systeminterface = NULL;
|
||||
|
||||
|
@ -256,7 +261,6 @@ MainWindow::~MainWindow()
|
|||
// delete systeminterface;
|
||||
// systeminterface = NULL;
|
||||
// }
|
||||
qDebug() << "mainwindow destroy...............";
|
||||
if (sessioninterface) {
|
||||
sessioninterface->deleteLater();
|
||||
}
|
||||
|
@ -623,7 +627,6 @@ void MainWindow::changeLanguage(LANGUAGE language)
|
|||
|
||||
void MainWindow::displayMainWindow(/*int count*/)
|
||||
{
|
||||
qDebug() << "displayMainWindow============";
|
||||
this->battery = sessioninterface->judge_power_is_exists_qt();
|
||||
this->sensor = systeminterface->judge_sensors_exists_qt();
|
||||
login_widget->setSessionDbusProxy(sessioninterface);
|
||||
|
@ -706,7 +709,7 @@ void MainWindow::startDbusDaemon()
|
|||
|
||||
// connect(systeminterface, &SystemDispatcher::dbusInitFinished, this, [=] {dlg.close();this->displayMainWindow();
|
||||
// });
|
||||
connect(systeminterface, SIGNAL(dbusInitFinished()), this, SLOT(displayMainWindow()), Qt::QueuedConnection);//数据获取完毕后,告诉界面去更新数据后显示界面
|
||||
connect(systeminterface, SIGNAL(dbusInitFinished()), this, SLOT(displayMainWindow()));//数据获取完毕后,告诉界面去更新数据后显示界面
|
||||
systemThread->start();
|
||||
|
||||
|
||||
|
@ -953,12 +956,10 @@ void MainWindow::closeYoukerAssistant() {
|
|||
connect(animation, SIGNAL(finished()), this, SLOT(close()));
|
||||
}
|
||||
|
||||
void MainWindow::closeEvent(QCloseEvent *event)
|
||||
void MainWindow::closeEvent(QCloseEvent *)
|
||||
{
|
||||
qDebug() << "MainWindow::closeEvent.....";
|
||||
// QApplication::quit();
|
||||
qApp->exit();
|
||||
// QDialog::closeEvent(event);
|
||||
}
|
||||
|
||||
void MainWindow::setCurrentPageIndex(int index)
|
||||
|
@ -1294,13 +1295,21 @@ void MainWindow::setupConfigure()
|
|||
|
||||
}
|
||||
|
||||
void MainWindow::createAboutDialog()
|
||||
{
|
||||
QApplication::setOverrideCursor(Qt::WaitCursor);
|
||||
aboutDlg = new AboutDialog(0, last_skin_path, this->arch, this->osName);
|
||||
aboutDlg->setModal(false);
|
||||
QApplication::restoreOverrideCursor();
|
||||
}
|
||||
|
||||
void MainWindow::aboutUs()
|
||||
{
|
||||
int w_x = this->frameGeometry().topLeft().x() + (900 / 2) - (442 / 2);
|
||||
/*int w_x = this->frameGeometry().topLeft().x() + (900 / 2) - (442 / 2);
|
||||
int w_y = this->frameGeometry().topLeft().y() + (600 /2) - (326 / 2);
|
||||
if(aboutDlg == NULL)
|
||||
{
|
||||
aboutDlg = new AboutDialog(0, /*version, */last_skin_path, this->arch, this->osName);
|
||||
aboutDlg = new AboutDialog(0, last_skin_path, this->arch, this->osName);
|
||||
aboutDlg->move(w_x, w_y);
|
||||
aboutDlg->show();
|
||||
aboutDlg->raise();
|
||||
|
@ -1309,7 +1318,14 @@ void MainWindow::aboutUs()
|
|||
aboutDlg->move(w_x, w_y);
|
||||
aboutDlg->show();
|
||||
aboutDlg->raise();
|
||||
}*/
|
||||
if (!aboutDlg) {
|
||||
createAboutDialog();
|
||||
}
|
||||
int w_x = this->frameGeometry().topLeft().x() + (900 / 2) - (442 / 2);
|
||||
int w_y = this->frameGeometry().topLeft().y() + (600 /2) - (326 / 2);
|
||||
aboutDlg->move(w_x, w_y);
|
||||
aboutDlg->show();
|
||||
}
|
||||
|
||||
|
||||
|
|
|
@ -24,6 +24,7 @@
|
|||
#include <QWidget>
|
||||
#include <QPixmap>
|
||||
#include <QSettings>
|
||||
#include <QDesktopWidget>
|
||||
|
||||
#include "titlewidget.h"
|
||||
#include "actionwidget.h"
|
||||
|
@ -54,12 +55,14 @@ class ShadowWidget;
|
|||
#include "autostartwidget.h"
|
||||
//#include "cameramanager.h"
|
||||
|
||||
class MainWindow : public QDialog
|
||||
//class MainWindow : public QDialog
|
||||
class MainWindow : public QMainWindow
|
||||
{
|
||||
Q_OBJECT
|
||||
|
||||
public:
|
||||
explicit MainWindow(QString cur_arch = "", int d_count = 0, QWidget *parent = 0);
|
||||
// explicit MainWindow(QString cur_arch = "", int d_count = 0, QWidget *parent = 0);
|
||||
explicit MainWindow(QString cur_arch = "", int d_count = 0, QWidget* parent = 0, Qt::WindowFlags flags = 0);
|
||||
~MainWindow();
|
||||
void setTranslator(QTranslator* translator);
|
||||
void initConnect();
|
||||
|
@ -78,6 +81,8 @@ public:
|
|||
bool CopyFile(QString filename);
|
||||
QString accessOSName();
|
||||
|
||||
void createAboutDialog();
|
||||
|
||||
protected:
|
||||
void mousePressEvent(QMouseEvent *event);
|
||||
void mouseReleaseEvent(QMouseEvent *event);
|
||||
|
|
|
@ -20,7 +20,6 @@
|
|||
#include "pluginmanager.h"
|
||||
#include "../component/plugininterface.h"
|
||||
#include <QDir>
|
||||
#include <QApplication>
|
||||
#include <QDebug>
|
||||
|
||||
PluginManager::PluginManager(void)
|
||||
|
@ -40,19 +39,9 @@ PluginManager* PluginManager::Instance()
|
|||
|
||||
bool PluginManager::loadPlugin(QString plugin_path)
|
||||
{
|
||||
/*QDir pluginsDir(qApp->applicationDirPath());//QCoreApplication::applicationDirPath()
|
||||
#ifdef QT_DEBUG
|
||||
pluginsDir.cd("libs");
|
||||
#else
|
||||
pluginsDir.cd("../libs");
|
||||
#endif*/
|
||||
|
||||
QDir pluginsDir(plugin_path + "/libs");
|
||||
foreach (QString fileName, pluginsDir.entryList(QStringList("*.so"),QDir::Files)) {
|
||||
if (!QLibrary::isLibrary(fileName))
|
||||
continue;
|
||||
|
||||
QPluginLoader *pluginLoader = new QPluginLoader(pluginsDir.absoluteFilePath(fileName));
|
||||
QPluginLoader *pluginLoader = new QPluginLoader(pluginsDir.absoluteFilePath(fileName));
|
||||
QObject *plugin = pluginLoader->instance();
|
||||
if (plugin) {//测试插件是否有效:使用 qobject_cast()测试插件是否给出了相应接口并进行类型转换,转换成接口对象指针.
|
||||
PluginInterface* interface = qobject_cast<PluginInterface*>(plugin);
|
||||
|
@ -60,10 +49,6 @@ bool PluginManager::loadPlugin(QString plugin_path)
|
|||
QString guid = interface->getGuid();
|
||||
plugin_map.insert(guid, pluginLoader);
|
||||
}
|
||||
else {
|
||||
pluginLoader->unload();
|
||||
pluginLoader->deleteLater();
|
||||
}
|
||||
}
|
||||
else {
|
||||
delete pluginLoader;
|
||||
|
@ -83,3 +68,47 @@ bool PluginManager::unloadPlugin(QString plugin_guid)
|
|||
plugin_map.erase(iter);
|
||||
return true;
|
||||
}
|
||||
|
||||
|
||||
/*PluginManager::PluginManager(QObject *parent)
|
||||
: QObject(parent)
|
||||
{
|
||||
}
|
||||
|
||||
PluginManager::~PluginManager(void)
|
||||
{
|
||||
}
|
||||
|
||||
PluginManager* PluginManager::Instance()
|
||||
{
|
||||
static PluginManager PluginMgr;
|
||||
return &PluginMgr;
|
||||
}
|
||||
|
||||
void PluginManager::loadPlugin(QString plugin_path)
|
||||
{
|
||||
QDir pluginsDir(plugin_path + "/libs");
|
||||
|
||||
const QStringList plugins = pluginsDir.entryList(QStringList("*.so"), QDir::Files);
|
||||
for (const QString file : plugins)
|
||||
{
|
||||
if (!QLibrary::isLibrary(file))
|
||||
continue;
|
||||
|
||||
QPluginLoader *pluginLoader = new QPluginLoader(pluginsDir.absoluteFilePath(file), this);
|
||||
PluginInterface *interface = qobject_cast<PluginInterface *>(pluginLoader->instance());
|
||||
if (!interface)
|
||||
{
|
||||
qWarning() << pluginLoader->errorString();
|
||||
pluginLoader->unload();
|
||||
pluginLoader->deleteLater();
|
||||
return;
|
||||
} else {
|
||||
qDebug() << "The plugin interface is: " << interface;
|
||||
}
|
||||
|
||||
QWidget *w = interface->centralWidget();
|
||||
w->setVisible(false);
|
||||
emit pluginAdded(w);
|
||||
}
|
||||
}*/
|
||||
|
|
|
@ -1,8 +1,6 @@
|
|||
#ifndef PLUGINSMANAGER_H
|
||||
#define PLUGINSMANAGER_H
|
||||
|
||||
#include <QMap>
|
||||
#include <QPluginLoader>
|
||||
#include <QObject>
|
||||
|
||||
class PluginManager
|
||||
{
|
||||
|
@ -65,32 +63,19 @@ private:
|
|||
};
|
||||
|
||||
|
||||
|
||||
/*#include "frameproxyinterface.h"
|
||||
|
||||
#include <QObject>
|
||||
|
||||
using namespace dcc;
|
||||
|
||||
class PluginsController : public QObject, public FrameProxyInterface
|
||||
/*class PluginManager : public QObject
|
||||
{
|
||||
Q_OBJECT
|
||||
|
||||
public:
|
||||
explicit PluginsController(QObject *parent = 0);
|
||||
explicit PluginManager(QObject *parent = 0);
|
||||
~PluginManager();
|
||||
|
||||
static PluginManager* Instance();
|
||||
|
||||
signals:
|
||||
void pluginAdded(QWidget * const w);
|
||||
void requestModulePage(const QString &module, const QString &page);
|
||||
void pluginAdded(QWidget *const w);
|
||||
|
||||
public slots:
|
||||
void loadPlugins();
|
||||
|
||||
private:
|
||||
void pushWidget(ModuleInterface * const, ContentWidget * const) {}
|
||||
void setFrameAutoHide(ModuleInterface * const, const bool) {}
|
||||
void setModuleVisible(ModuleInterface * const, const bool) {}
|
||||
void showModulePage(const QString &module, const QString &page);
|
||||
void loadPlugin(QString plugin_path);
|
||||
};*/
|
||||
|
||||
#endif // PLUGINSMANAGER_H
|
||||
|
|
Binary file not shown.
After Width: | Height: | Size: 1.7 KiB |
|
@ -1,208 +0,0 @@
|
|||
/*
|
||||
* Copyright (C) 2013 ~ 2015 National University of Defense Technology(NUDT) & Kylin Ltd.
|
||||
*
|
||||
* Authors:
|
||||
* Kobe Lee xiangli@ubuntukylin.com/kobe24_lixiang@126.com
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation; version 3.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*/
|
||||
|
||||
#include "skincenter.h"
|
||||
#include "mainwindow.h"
|
||||
#include <QDebug>
|
||||
#include <QVBoxLayout>
|
||||
|
||||
SkinCenter::SkinCenter(QWidget *parent/*, Qt::WindowFlags f*/)
|
||||
:QDialog(parent)
|
||||
{
|
||||
this->setFixedSize(500, 271);
|
||||
this->setStyleSheet("QDialog{border: 1px solid gray;border-radius:2px}");
|
||||
setWindowFlags(Qt::FramelessWindowHint);
|
||||
title_bar = new KylinTitleBar();
|
||||
list_widget = new KylinListWidget();
|
||||
connect(list_widget, SIGNAL(sendBackgroundName(QString)), this, SLOT(changeSkinCenterBackground(QString)));
|
||||
list_widget->setMouseTracking(true);//hover need it
|
||||
list_widget->setAutoFillBackground(false);
|
||||
|
||||
using_label = new QLabel(list_widget);
|
||||
using_label->setFixedSize(17, 26);
|
||||
using_label->setAutoFillBackground(true);
|
||||
QPalette palette;
|
||||
// palette.setBrush(using_label->backgroundRole(), QBrush(QPixmap("://res/clothes.png")));
|
||||
palette.setBrush(QPalette::Background, QBrush(QPixmap("://res/clothes.png")));
|
||||
using_label->setPalette(palette);
|
||||
using_label->show();
|
||||
|
||||
// QHBoxLayout *list_layout = new QHBoxLayout();
|
||||
// list_layout->addWidget(list_widget);
|
||||
// list_layout->setSpacing(0);
|
||||
// list_layout->setMargin(0);
|
||||
// list_layout->setContentsMargins(1, 0, 1, 1);
|
||||
|
||||
// QVBoxLayout *layout = new QVBoxLayout();
|
||||
// layout->addWidget(title_bar);
|
||||
//// layout->addWidget(list_widget);
|
||||
// layout->addLayout(list_layout);
|
||||
// layout->setSpacing(0);
|
||||
// layout->setMargin(0);
|
||||
// layout->setContentsMargins(0, 0, 0, 0);
|
||||
// setLayout(layout);
|
||||
|
||||
|
||||
QGridLayout *grid_layout = new QGridLayout();
|
||||
grid_layout->addWidget(list_widget);
|
||||
QVBoxLayout *layout = new QVBoxLayout();
|
||||
layout->addWidget(title_bar);
|
||||
layout->addLayout(grid_layout);
|
||||
layout->setSpacing(0);
|
||||
layout->setMargin(0);
|
||||
layout->setContentsMargins(0, 0, 0, 0);
|
||||
setLayout(layout);
|
||||
|
||||
|
||||
// delayTimer = QTimer();
|
||||
|
||||
this->setLanguage();
|
||||
this->initConnect();
|
||||
}
|
||||
|
||||
SkinCenter::~SkinCenter()
|
||||
{
|
||||
// disconnect(delayTimer,SIGNAL(timeout()),this,SLOT(changeAnimationStep()));
|
||||
// if(delayTimer->isActive()) {
|
||||
// delayTimer->stop();
|
||||
// }
|
||||
// if (delayTimer != NULL) {
|
||||
// delete delayTimer;
|
||||
// delayTimer = NULL;
|
||||
// }
|
||||
}
|
||||
|
||||
void SkinCenter::setLanguage()
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
void SkinCenter::initConnect()
|
||||
{
|
||||
connect(title_bar,SIGNAL(closeDialog()), this, SLOT(onCloseButtonClicked()));
|
||||
// connect(delayTimer, SIGNAL(timeout()), this, SLOT(changeAnimationStep()));
|
||||
}
|
||||
|
||||
void SkinCenter::onCloseButtonClicked()
|
||||
{
|
||||
this->close();
|
||||
}
|
||||
|
||||
void SkinCenter::changeSkinCenterBackground(QString pciture)
|
||||
{
|
||||
int index = 1;
|
||||
last_skin_path = pciture;
|
||||
title_bar->resetBackground(last_skin_path);
|
||||
int start_pos = pciture.lastIndexOf("/") + 1;
|
||||
int end_pos = pciture.length();
|
||||
index = pciture.mid(start_pos, end_pos-start_pos).replace(".png", "").toInt();
|
||||
qDebug() << index;
|
||||
QListWidgetItem *cur_item = list_widget->item(index - 1);
|
||||
this->initUsingLogo(cur_item);
|
||||
}
|
||||
|
||||
void SkinCenter::initBackgroundList()
|
||||
{
|
||||
list_widget->setIconSize(QSize(150, 100));
|
||||
list_widget->setResizeMode(QListView::Adjust);
|
||||
list_widget->setViewMode(QListView::IconMode);
|
||||
list_widget->setMovement(QListView::Static);
|
||||
list_widget->setSpacing(9);
|
||||
list_widget->setMainWindow(mainwindow);
|
||||
|
||||
list_widget->setFocusPolicy(Qt::NoFocus);
|
||||
|
||||
for(int index = 0; index < 4; ++index)
|
||||
{
|
||||
QString iconPath = QString(":/background/res/skin/%1.png").arg(index + 1);
|
||||
QPixmap pixMap(iconPath);
|
||||
KylinListWidgetItem *item = new KylinListWidgetItem(QIcon(pixMap.scaled(QSize(150,100))), "");
|
||||
item->setMainWindow(mainwindow);
|
||||
item->setSkinName(iconPath);
|
||||
item->setSizeHint(QSize(150,100));
|
||||
list_widget->insertItem(index, item);
|
||||
}
|
||||
|
||||
// qDebug() << mainwindow->getCurrentBackgroundIndex();
|
||||
// QListWidgetItem *cur_item = list_widget->item(mainwindow->getCurrentBackgroundIndex() - 1);
|
||||
// this->initUsingLogo(cur_item);
|
||||
}
|
||||
|
||||
void SkinCenter::initTitleBar(const QString &path)
|
||||
{
|
||||
title_bar->setTitleWidth(500);
|
||||
title_bar->setTitleName(tr("Skin Center"));
|
||||
last_skin_path = path;
|
||||
title_bar->setTitleBackgound(last_skin_path);
|
||||
}
|
||||
|
||||
void SkinCenter::setLogo()
|
||||
{
|
||||
qDebug() << mainwindow->getCurrentBackgroundIndex();
|
||||
QListWidgetItem *cur_item = list_widget->item(mainwindow->getCurrentBackgroundIndex() - 1);
|
||||
this->initUsingLogo(cur_item);
|
||||
}
|
||||
|
||||
|
||||
void SkinCenter::initUsingLogo(QListWidgetItem *init_item) {
|
||||
// int nRowIndex = list_widget->row(init_item);
|
||||
QRect rect = list_widget->visualItemRect(init_item);
|
||||
QPoint p = rect.topLeft();
|
||||
using_label->move(p.x(), p.y());
|
||||
qDebug() << p.x();
|
||||
qDebug() << p.y();
|
||||
qDebug() <<"----------------";
|
||||
// QPoint p = rect.bottomRight();
|
||||
// using_label->move(p.x()-20, p.y()-40);
|
||||
//reset current item status
|
||||
// QListWidgetItem *pre_item = list_widget->item(current_index);
|
||||
// pre_item->setTextColor(QColor(0, 0, 255, 127));
|
||||
// current_index = nRowIndex;
|
||||
// init_item->setTextColor(QColor("4f4f4f"));
|
||||
}
|
||||
|
||||
//void MainWindow::reViewThePointSkin(QString pciture)
|
||||
//{
|
||||
// if (review_skin_pixmap.isDetached())
|
||||
// {
|
||||
// review_skin_pixmap.detach();
|
||||
// }
|
||||
|
||||
// review_skin_pixmap.load(pciture);
|
||||
// QPalette palette_back;
|
||||
// palette_back.setBrush(QPalette::Background, review_skin_pixmap);
|
||||
// action_widget->setPalette(palette_back);
|
||||
//}
|
||||
|
||||
//void SkinCenter::enterEvent (QEvent *)
|
||||
//{
|
||||
// delayTimer->start(300);
|
||||
//}
|
||||
|
||||
//void SkinCenter::leaveEvent (QEvent *)
|
||||
//{
|
||||
// if(delayTimer->isActive())
|
||||
// delayTimer->stop();
|
||||
//}
|
||||
|
||||
void SkinCenter::closeEvent(QCloseEvent *event)
|
||||
{
|
||||
title_bar->setTitleBackgound(last_skin_path);
|
||||
mainwindow->restoreSkin();
|
||||
}
|
|
@ -1,65 +0,0 @@
|
|||
/*
|
||||
* Copyright (C) 2013 ~ 2015 National University of Defense Technology(NUDT) & Kylin Ltd.
|
||||
*
|
||||
* Authors:
|
||||
* Kobe Lee xiangli@ubuntukylin.com/kobe24_lixiang@126.com
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation; version 3.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*/
|
||||
|
||||
#ifndef SKINCENTER_H
|
||||
#define SKINCENTER_H
|
||||
|
||||
#include <QDialog>
|
||||
//#include <QTimer>
|
||||
|
||||
#include "../component/kylinlistwidget.h"
|
||||
#include "../component/kylintitlebar.h"
|
||||
#include "../component/kylinlistwidgetitem.h"
|
||||
|
||||
class MainWindow;
|
||||
|
||||
class SkinCenter :public QDialog
|
||||
{
|
||||
Q_OBJECT
|
||||
public:
|
||||
SkinCenter(QWidget *parent = 0/*, Qt::WindowFlags f = 0*/);
|
||||
~SkinCenter();
|
||||
void setParentWindow(MainWindow *From) { mainwindow = From;}
|
||||
void initBackgroundList();
|
||||
void setLanguage();
|
||||
void initConnect();
|
||||
void initTitleBar(const QString &path);
|
||||
void initUsingLogo(QListWidgetItem *init_item);
|
||||
void setLogo();
|
||||
|
||||
public slots:
|
||||
void onCloseButtonClicked();
|
||||
void changeSkinCenterBackground(QString pciture);
|
||||
|
||||
protected:
|
||||
// virtual void enterEvent (QEvent *);
|
||||
// virtual void leaveEvent (QEvent *);
|
||||
void closeEvent(QCloseEvent *event);
|
||||
|
||||
private:
|
||||
MainWindow *mainwindow;
|
||||
KylinTitleBar *title_bar;
|
||||
KylinListWidget *list_widget;
|
||||
QString last_skin_path;
|
||||
QLabel *using_label;
|
||||
// QTimer *delayTimer;
|
||||
// QString titlebar_pic;
|
||||
};
|
||||
|
||||
#endif // SKINCENTER_H
|
|
@ -23,7 +23,6 @@
|
|||
#include <QVBoxLayout>
|
||||
#include <QPropertyAnimation>
|
||||
#include <QParallelAnimationGroup>
|
||||
#include <QFileDialog>
|
||||
|
||||
//20161228
|
||||
SkinCenter::SkinCenter(QWidget *parent, QString skin, QString arch, QString os)
|
||||
|
|
|
@ -21,6 +21,7 @@
|
|||
#define SKINCENTER_H
|
||||
|
||||
#include <QDialog>
|
||||
#include <QFileDialog>
|
||||
//#include <QTimer>
|
||||
|
||||
#include "../component/kylinlistwidget.h"
|
||||
|
|
58
src/src.pro
58
src/src.pro
|
@ -11,7 +11,57 @@ CONFIG += qt warn_on
|
|||
CONFIG += release
|
||||
CONFIG += link_pkgconfig
|
||||
|
||||
QT += dbus network
|
||||
QT += core dbus network
|
||||
#QT += core dbus network
|
||||
|
||||
##greaterThan(QT_MAJOR_VERSION, 4): QT += widgets
|
||||
#isEqual(QT_MAJOR_VERSION, 5) {
|
||||
# QT += widgets gui
|
||||
#}
|
||||
|
||||
#TARGET = kylin-assistant
|
||||
#DESTDIR = ../
|
||||
#TEMPLATE = app
|
||||
#CONFIG += qt \
|
||||
# warn_on \
|
||||
# release \
|
||||
# link_pkgconfig
|
||||
#INCLUDEPATH += .
|
||||
|
||||
#include(../qtsingleapplication/src/qtsingleapplication.pri)
|
||||
|
||||
#QMAKE_CFLAGS_DEBUG = -g
|
||||
|
||||
##指定uic命令将.ui文件转化成ui_*.h文件的存放的目录
|
||||
#UI_DIR += $$PWD/../tmp/
|
||||
|
||||
##指定rcc命令将.qrc文件转换成qrc_*.h文件的存放目录
|
||||
#RCC_DIR += $$PWD/../tmp/
|
||||
|
||||
##指定moc命令将含Q_OBJECT的头文件转换成标准.h文件的存放目录
|
||||
#MOC_DIR += $$PWD/../tmp/
|
||||
|
||||
##指定目标文件(obj)的存放目录
|
||||
##OBJECTS_DIR += $$PWD/../tmp/
|
||||
|
||||
#CONFIG(debug,debug|release){
|
||||
# message(debug)
|
||||
|
||||
# DEFINES += _DEBUG
|
||||
|
||||
## DESTDIR = $$PWD/../bin/Debug
|
||||
# OBJECTS_DIR = $$PWD/../obj/Debug
|
||||
#}
|
||||
|
||||
#CONFIG(release,debug|release){
|
||||
# message(release)
|
||||
|
||||
## DESTDIR = $$PWD/../bin/Release
|
||||
# OBJECTS_DIR = $$PWD/../obj/Release
|
||||
|
||||
# QMAKE_CFLAGS += -Os -s
|
||||
# QMAKE_CXXFLAGS += -Os -s
|
||||
#}
|
||||
|
||||
inst1.files += res/kylin-assistant.png
|
||||
inst1.path = /usr/share/pixmaps
|
||||
|
@ -91,11 +141,13 @@ SOURCES += main.cpp\
|
|||
../setting/iconwidget.cpp \
|
||||
../setting/mousewidget.cpp \
|
||||
../setting/voicewidget.cpp \
|
||||
# ../setting/animationwidget.cpp \
|
||||
../setting/launcherwidget.cpp \
|
||||
../setting/panelwidget.cpp \
|
||||
../setting/windowwidget.cpp \
|
||||
../setting/fontwidget.cpp \
|
||||
../setting/touchpadwidget.cpp \
|
||||
# ../setting/deadpixelwidget.cpp \
|
||||
../setting/conservewidget.cpp \
|
||||
../setting/nautiluswidget.cpp \
|
||||
../component/scrollwidget.cpp \
|
||||
|
@ -182,11 +234,13 @@ HEADERS += mainwindow.h \
|
|||
../setting/iconwidget.h \
|
||||
../setting/mousewidget.h \
|
||||
../setting/voicewidget.h \
|
||||
# ../setting/animationwidget.h \
|
||||
../setting/launcherwidget.h \
|
||||
../setting/panelwidget.h \
|
||||
../setting/windowwidget.h \
|
||||
../setting/fontwidget.h \
|
||||
../setting/touchpadwidget.h \
|
||||
# ../setting/deadpixelwidget.h \
|
||||
../setting/conservewidget.h \
|
||||
../setting/nautiluswidget.h \
|
||||
../component/scrollwidget.h \
|
||||
|
@ -230,6 +284,7 @@ FORMS += \
|
|||
../component/quibo.ui \
|
||||
../component/alertdialog.ui \
|
||||
autostartwidget.ui \
|
||||
# aboutdialog.ui \
|
||||
../cleaner/cleanlistwidget.ui \
|
||||
../cleaner/cleanerdetailwidget.ui \
|
||||
../component/itemcard.ui \
|
||||
|
@ -238,7 +293,6 @@ FORMS += \
|
|||
RESOURCES += \
|
||||
img.qrc
|
||||
|
||||
|
||||
INCLUDEPATH += qtsingleapplication
|
||||
DEPENDPATH += qtsingleapplication
|
||||
|
||||
|
|
|
@ -34,6 +34,7 @@ UpgradeDialog::UpgradeDialog(QWidget *parent, /*const QString &version, */QStrin
|
|||
|
||||
isBusy = false;
|
||||
upgradeOver = false;
|
||||
// cur_version = version;
|
||||
cur_version = qApp->applicationVersion();
|
||||
|
||||
baseWidget = new QWidget(this);
|
||||
|
|
Loading…
Reference in New Issue