reformatted to Mozilla code style

This commit is contained in:
Jeremy Borgman
2020-09-04 20:16:33 -05:00
committed by borgmanJeremy
parent c0e2e48db4
commit c8d15205be
176 changed files with 12695 additions and 11269 deletions

View File

@@ -17,100 +17,99 @@
#include "toolfactory.h"
#include "arrow/arrowtool.h"
#include "blur/blurtool.h"
#include "circle/circletool.h"
#include "circlecount/circlecounttool.h"
#include "copy/copytool.h"
#include "exit/exittool.h"
#include "imgur/imguruploadertool.h"
#include "launcher/applaunchertool.h"
#include "line/linetool.h"
#include "marker/markertool.h"
#include "move/movetool.h"
#include "pencil/penciltool.h"
#include "pin/pintool.h"
#include "rectangle/rectangletool.h"
#include "redo/redotool.h"
#include "save/savetool.h"
#include "selection/selectiontool.h"
#include "sizeindicator/sizeindicatortool.h"
#include "undo/undotool.h"
#include "launcher/applaunchertool.h"
#include "blur/blurtool.h"
#include "redo/redotool.h"
#include "pin/pintool.h"
#include "text/texttool.h"
#include "undo/undotool.h"
ToolFactory::ToolFactory(QObject *parent) : QObject(parent) {
ToolFactory::ToolFactory(QObject* parent)
: QObject(parent)
{}
}
CaptureTool* ToolFactory::CreateTool(
CaptureButton::ButtonType t,
QObject *parent)
CaptureTool*
ToolFactory::CreateTool(CaptureButton::ButtonType t, QObject* parent)
{
CaptureTool *tool;
switch (t) {
CaptureTool* tool;
switch (t) {
case CaptureButton::TYPE_ARROW:
tool = new ArrowTool(parent);
break;
tool = new ArrowTool(parent);
break;
case CaptureButton::TYPE_CIRCLE:
tool = new CircleTool(parent);
break;
tool = new CircleTool(parent);
break;
case CaptureButton::TYPE_COPY:
tool = new CopyTool(parent);
break;
tool = new CopyTool(parent);
break;
case CaptureButton::TYPE_EXIT:
tool = new ExitTool(parent);
break;
tool = new ExitTool(parent);
break;
case CaptureButton::TYPE_IMAGEUPLOADER:
tool = new ImgurUploaderTool(parent);
break;
tool = new ImgurUploaderTool(parent);
break;
case CaptureButton::TYPE_DRAWER:
tool = new LineTool(parent);
break;
tool = new LineTool(parent);
break;
case CaptureButton::TYPE_MARKER:
tool = new MarkerTool(parent);
break;
tool = new MarkerTool(parent);
break;
case CaptureButton::TYPE_MOVESELECTION:
tool = new MoveTool(parent);
break;
tool = new MoveTool(parent);
break;
case CaptureButton::TYPE_PENCIL:
tool = new PencilTool(parent);
break;
tool = new PencilTool(parent);
break;
case CaptureButton::TYPE_RECTANGLE:
tool = new RectangleTool(parent);
break;
tool = new RectangleTool(parent);
break;
case CaptureButton::TYPE_SAVE:
tool = new SaveTool(parent);
break;
tool = new SaveTool(parent);
break;
case CaptureButton::TYPE_SELECTION:
tool = new SelectionTool(parent);
break;
tool = new SelectionTool(parent);
break;
case CaptureButton::TYPE_SELECTIONINDICATOR:
tool = new SizeIndicatorTool(parent);
break;
tool = new SizeIndicatorTool(parent);
break;
case CaptureButton::TYPE_UNDO:
tool = new UndoTool(parent);
break;
tool = new UndoTool(parent);
break;
case CaptureButton::TYPE_REDO:
tool = new RedoTool(parent);
break;
tool = new RedoTool(parent);
break;
case CaptureButton::TYPE_OPEN_APP:
tool = new AppLauncher(parent);
break;
tool = new AppLauncher(parent);
break;
case CaptureButton::TYPE_BLUR:
tool = new BlurTool(parent);
break;
tool = new BlurTool(parent);
break;
case CaptureButton::TYPE_PIN:
tool = new PinTool(parent);
break;
tool = new PinTool(parent);
break;
case CaptureButton::TYPE_TEXT:
tool = new TextTool(parent);
break;
tool = new TextTool(parent);
break;
case CaptureButton::TYPE_CIRCLECOUNT:
tool = new CircleCountTool(parent);
break;
tool = new CircleCountTool(parent);
break;
default:
tool = nullptr;
break;
}
return tool;
tool = nullptr;
break;
}
return tool;
}