Skip to content

Commit

Permalink
✨ Apply clang-format
Browse files Browse the repository at this point in the history
  • Loading branch information
Schneegans committed Jan 27, 2025
1 parent 68da2e3 commit af5b6c2
Show file tree
Hide file tree
Showing 71 changed files with 85 additions and 85 deletions.
2 changes: 1 addition & 1 deletion plugins/csl-tools/src/DeletableMark.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ class CSL_TOOLS_EXPORT DeletableMark : public Mark {
DeletableMark(DeletableMark&& other) = delete;

DeletableMark& operator=(DeletableMark const& other) = delete;
DeletableMark& operator=(DeletableMark&& other) = delete;
DeletableMark& operator=(DeletableMark&& other) = delete;

~DeletableMark() override;

Expand Down
2 changes: 1 addition & 1 deletion plugins/csl-tools/src/Mark.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -306,7 +306,7 @@ void Mark::initData() {
double height = surface ? surface->getHeight(lngLat) : 0.0;
auto radii = object->getRadii();
mPosition = cs::utils::convert::toCartesian(
lngLat, radii, height * mSettings->mGraphics.pHeightScale.get());
lngLat, radii, height * mSettings->mGraphics.pHeightScale.get());
});

// connect the heightscale value to this object. Whenever the heightscale value changes
Expand Down
2 changes: 1 addition & 1 deletion plugins/csl-tools/src/Mark.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ class CSL_TOOLS_EXPORT Mark : public IVistaOpenGLDraw, public Tool {
Mark(Mark&& other) = default;

Mark& operator=(Mark const& other) = delete;
Mark& operator=(Mark&& other) = delete;
Mark& operator=(Mark&& other) = delete;

~Mark() override;

Expand Down
2 changes: 1 addition & 1 deletion plugins/csl-tools/src/MultiPointTool.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ class CSL_TOOLS_EXPORT MultiPointTool : public Tool {
MultiPointTool(MultiPointTool&& other) = delete;

MultiPointTool& operator=(MultiPointTool const& other) = delete;
MultiPointTool& operator=(MultiPointTool&& other) = delete;
MultiPointTool& operator=(MultiPointTool&& other) = delete;

~MultiPointTool() override;

Expand Down
2 changes: 1 addition & 1 deletion plugins/csl-tools/src/Tool.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ class CSL_TOOLS_EXPORT Tool {
Tool(Tool const& other) = default;
Tool(Tool&& other) noexcept = default;

Tool& operator=(Tool const& other) = default;
Tool& operator=(Tool const& other) = default;
Tool& operator=(Tool&& other) noexcept = default;

virtual ~Tool() = default;
Expand Down
2 changes: 1 addition & 1 deletion plugins/csp-anchor-labels/src/AnchorLabel.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ class AnchorLabel {
AnchorLabel(AnchorLabel&& other) = delete;

AnchorLabel& operator=(AnchorLabel const& other) = delete;
AnchorLabel& operator=(AnchorLabel&& other) = delete;
AnchorLabel& operator=(AnchorLabel&& other) = delete;

void update();

Expand Down
2 changes: 1 addition & 1 deletion plugins/csp-lod-bodies/src/BaseTileData.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ class BaseTileData {
BaseTileData(BaseTileData&& other) = default;

BaseTileData& operator=(BaseTileData const& other) = delete;
BaseTileData& operator=(BaseTileData&& other) = default;
BaseTileData& operator=(BaseTileData&& other) = default;

/// Returns the enum value for the data type stored in this tile.
virtual TileDataType getDataType() const = 0;
Expand Down
2 changes: 1 addition & 1 deletion plugins/csp-lod-bodies/src/LodBody.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ class LodBody : public cs::scene::CelestialSurface,
LodBody(LodBody&& other) = delete;

LodBody& operator=(LodBody const& other) = delete;
LodBody& operator=(LodBody&& other) = delete;
LodBody& operator=(LodBody&& other) = delete;

~LodBody() override;

Expand Down
2 changes: 1 addition & 1 deletion plugins/csp-lod-bodies/src/MinMaxPyramid.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ class MinMaxPyramid {
MinMaxPyramid(MinMaxPyramid&& other) = default;

MinMaxPyramid& operator=(MinMaxPyramid const& other) = default;
MinMaxPyramid& operator=(MinMaxPyramid&& other) = default;
MinMaxPyramid& operator=(MinMaxPyramid&& other) = default;

virtual ~MinMaxPyramid() = default;

Expand Down
2 changes: 1 addition & 1 deletion plugins/csp-lod-bodies/src/PlanetShader.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ class PlanetShader : public TerrainShader {
PlanetShader(PlanetShader&& other) = delete;

PlanetShader& operator=(PlanetShader const& other) = delete;
PlanetShader& operator=(PlanetShader&& other) = delete;
PlanetShader& operator=(PlanetShader&& other) = delete;

~PlanetShader() override;

Expand Down
2 changes: 1 addition & 1 deletion plugins/csp-lod-bodies/src/TerrainShader.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ class TerrainShader {
TerrainShader(TerrainShader&& other) = delete;

TerrainShader& operator=(TerrainShader const& other) = delete;
TerrainShader& operator=(TerrainShader&& other) = delete;
TerrainShader& operator=(TerrainShader&& other) = delete;

virtual ~TerrainShader() = default;

Expand Down
2 changes: 1 addition & 1 deletion plugins/csp-lod-bodies/src/TileData.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ class TileData : public BaseTileData {
TileData(TileData&& other) = delete;

TileData& operator=(TileData const& other) = delete;
TileData& operator=(TileData&& other) = delete;
TileData& operator=(TileData&& other) = delete;

~TileData() override;

Expand Down
2 changes: 1 addition & 1 deletion plugins/csp-lod-bodies/src/TileNode.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ class TileNode {
TileNode(TileNode&& other) = default;

TileNode& operator=(TileNode const& other) = delete;
TileNode& operator=(TileNode&& other) = default;
TileNode& operator=(TileNode&& other) = default;

/// Returns the tile data assigned to this. Can be null.
std::shared_ptr<BaseTileData> const& getTileData(TileDataType type) const;
Expand Down
2 changes: 1 addition & 1 deletion plugins/csp-lod-bodies/src/TileRenderer.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -278,7 +278,7 @@ void TileRenderer::renderTile(TileNode* node, UniformLocs const& locs) {
// Convert tile corners to camera-relative coordinates in double precision.
for (int i(0); i < 4; ++i) {
corners.at(i) = cs::utils::convert::toCartesian(cornersLngLat.at(i), mParams->mRadii,
averageHeight * static_cast<float>(mParams->mHeightScale));
averageHeight * static_cast<float>(mParams->mHeightScale));
cornersWorldSpace.at(i) = glm::fvec3(mMatM * glm::dvec4(corners.at(i), 1.0));

normals.at(i) = cs::utils::convert::lngLatToNormal(cornersLngLat.at(i));
Expand Down
2 changes: 1 addition & 1 deletion plugins/csp-lod-bodies/src/TileRenderer.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ class TileRenderer {
TileRenderer(TileRenderer&& other) = delete;

TileRenderer& operator=(TileRenderer const& other) = delete;
TileRenderer& operator=(TileRenderer&& other) = delete;
TileRenderer& operator=(TileRenderer&& other) = delete;

TreeManager* getTreeManager() const;

Expand Down
2 changes: 1 addition & 1 deletion plugins/csp-lod-bodies/src/TileSource.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ class TileSource {
TileSource(TileSource const& other) = default;
TileSource(TileSource&& other) noexcept = default;

TileSource& operator=(TileSource const& other) = default;
TileSource& operator=(TileSource const& other) = default;
TileSource& operator=(TileSource&& other) noexcept = default;

virtual ~TileSource() = default;
Expand Down
2 changes: 1 addition & 1 deletion plugins/csp-lod-bodies/src/TileSourceWebMapService.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ class TileSourceWebMapService : public TileSource {
TileSourceWebMapService(TileSourceWebMapService&& other) = delete;

TileSourceWebMapService& operator=(TileSourceWebMapService const& other) = delete;
TileSourceWebMapService& operator=(TileSourceWebMapService&& other) = delete;
TileSourceWebMapService& operator=(TileSourceWebMapService&& other) = delete;

~TileSourceWebMapService() override = default;

Expand Down
2 changes: 1 addition & 1 deletion plugins/csp-lod-bodies/src/TileTextureArray.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ class TileTextureArray {
TileTextureArray(TileTextureArray&& other) = delete;

TileTextureArray& operator=(TileTextureArray const& other) = delete;
TileTextureArray& operator=(TileTextureArray&& other) = delete;
TileTextureArray& operator=(TileTextureArray&& other) = delete;

~TileTextureArray();

Expand Down
2 changes: 1 addition & 1 deletion plugins/csp-lod-bodies/src/TreeManager.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ class TreeManager {
TreeManager(TreeManager&& other) = delete;

TreeManager& operator=(TreeManager const& other) = delete;
TreeManager& operator=(TreeManager&& other) = delete;
TreeManager& operator=(TreeManager&& other) = delete;

virtual ~TreeManager() = default;

Expand Down
2 changes: 1 addition & 1 deletion plugins/csp-lod-bodies/src/VistaPlanet.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ class VistaPlanet : public cs::graphics::ShadowCaster {
VistaPlanet(VistaPlanet&& other) = delete;

VistaPlanet& operator=(VistaPlanet const& other) = delete;
VistaPlanet& operator=(VistaPlanet&& other) = delete;
VistaPlanet& operator=(VistaPlanet&& other) = delete;

~VistaPlanet();

Expand Down
2 changes: 1 addition & 1 deletion plugins/csp-measurement-tools/src/DipStrikeTool.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ class DipStrikeTool : public IVistaOpenGLDraw, public csl::tools::MultiPointTool
DipStrikeTool(DipStrikeTool&& other) = delete;

DipStrikeTool& operator=(DipStrikeTool const& other) = delete;
DipStrikeTool& operator=(DipStrikeTool&& other) = delete;
DipStrikeTool& operator=(DipStrikeTool&& other) = delete;

~DipStrikeTool() override;

Expand Down
2 changes: 1 addition & 1 deletion plugins/csp-measurement-tools/src/EllipseTool.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ class EllipseTool : public IVistaOpenGLDraw, public csl::tools::Tool {
EllipseTool(EllipseTool&& other) = delete;

EllipseTool& operator=(EllipseTool const& other) = delete;
EllipseTool& operator=(EllipseTool&& other) = delete;
EllipseTool& operator=(EllipseTool&& other) = delete;

~EllipseTool() override;

Expand Down
2 changes: 1 addition & 1 deletion plugins/csp-measurement-tools/src/FlagTool.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ class FlagTool : public csl::tools::Mark {
FlagTool(FlagTool&& other) = delete;

FlagTool& operator=(FlagTool const& other) = delete;
FlagTool& operator=(FlagTool&& other) = delete;
FlagTool& operator=(FlagTool&& other) = delete;

~FlagTool() override;

Expand Down
2 changes: 1 addition & 1 deletion plugins/csp-measurement-tools/src/PathTool.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ class PathTool : public IVistaOpenGLDraw, public csl::tools::MultiPointTool {
PathTool(PathTool&& other) = delete;

PathTool& operator=(PathTool const& other) = delete;
PathTool& operator=(PathTool&& other) = delete;
PathTool& operator=(PathTool&& other) = delete;

~PathTool() override;

Expand Down
2 changes: 1 addition & 1 deletion plugins/csp-measurement-tools/src/PolygonTool.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ class PolygonTool : public IVistaOpenGLDraw, public csl::tools::MultiPointTool {
PolygonTool(PolygonTool&& other) = delete;

PolygonTool& operator=(PolygonTool const& other) = delete;
PolygonTool& operator=(PolygonTool&& other) = delete;
PolygonTool& operator=(PolygonTool&& other) = delete;

~PolygonTool() override;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ class BreakpointTree {
BreakpointTree(BreakpointTree&& other) = default;

BreakpointTree& operator=(BreakpointTree const& other) = default;
BreakpointTree& operator=(BreakpointTree&& other) = default;
BreakpointTree& operator=(BreakpointTree&& other) = default;

~BreakpointTree();

Expand Down
2 changes: 1 addition & 1 deletion plugins/csp-measurement-tools/src/voronoi/Vector2f.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ struct Vector2f {
Vector2f(Vector2f&& other) = default;

Vector2f& operator=(Vector2f const& other) = default;
Vector2f& operator=(Vector2f&& other) = default;
Vector2f& operator=(Vector2f&& other) = default;

~Vector2f() = default;

Expand Down
2 changes: 1 addition & 1 deletion plugins/csp-minimap/src/Plugin.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -195,7 +195,7 @@ void Plugin::onAddBookmark(std::shared_ptr<const cs::scene::CelestialObject> con
if (activeObject && activeObject->getCenterName() == bookmark.mLocation.value().mCenter) {
auto radii = activeObject->getRadii();
auto p = cs::utils::convert::cartesianToLngLat(
bookmark.mLocation.value().mPosition.value(), radii);
bookmark.mLocation.value().mPosition.value(), radii);
p = cs::utils::convert::toDegrees(p);
auto c = bookmark.mColor.value_or(glm::vec3(0.8F, 0.8F, 1.0F)) * 255.F;
mGuiManager->getGui()->callJavascript("CosmoScout.minimap.addBookmark", bookmarkID,
Expand Down
2 changes: 1 addition & 1 deletion plugins/csp-rings/src/Ring.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ class Ring : public cs::scene::CelestialObject, public IVistaOpenGLDraw {
Ring(Ring&& other) = default;

Ring& operator=(Ring const& other) = delete;
Ring& operator=(Ring&& other) = delete;
Ring& operator=(Ring&& other) = delete;

~Ring() override;

Expand Down
2 changes: 1 addition & 1 deletion plugins/csp-satellites/src/Satellite.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ class Satellite {
Satellite(Satellite&& other) = default;

Satellite& operator=(Satellite const& other) = delete;
Satellite& operator=(Satellite&& other) = delete;
Satellite& operator=(Satellite&& other) = delete;

~Satellite();

Expand Down
2 changes: 1 addition & 1 deletion plugins/csp-sharad/src/Sharad.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ class Sharad : public IVistaOpenGLDraw {
Sharad(Sharad&& other) = delete;

Sharad& operator=(Sharad const& other) = delete;
Sharad& operator=(Sharad&& other) = delete;
Sharad& operator=(Sharad&& other) = delete;

~Sharad();

Expand Down
2 changes: 1 addition & 1 deletion plugins/csp-simple-bodies/src/SimpleBody.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ class SimpleBody : public cs::scene::CelestialSurface,
SimpleBody(SimpleBody&& other) = default;

SimpleBody& operator=(SimpleBody const& other) = delete;
SimpleBody& operator=(SimpleBody&& other) = default;
SimpleBody& operator=(SimpleBody&& other) = default;

~SimpleBody() override;

Expand Down
2 changes: 1 addition & 1 deletion plugins/csp-timings/gui/js/csp-timings.js
Original file line number Diff line number Diff line change
Expand Up @@ -275,7 +275,7 @@ class TimingsApi extends IApi {
}

// Compute the number of required grid lines.
let ticks = Math.floor(maxTime / interval);
let ticks = Math.floor(maxTime / interval);
const gridLines = document.createElement('template');

for (let i = 0; i <= ticks; i++) {
Expand Down
2 changes: 1 addition & 1 deletion plugins/csp-trajectories/src/DeepSpaceDot.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ class DeepSpaceDot : public IVistaOpenGLDraw {
DeepSpaceDot(DeepSpaceDot&& other) = default;

DeepSpaceDot& operator=(DeepSpaceDot const& other) = delete;
DeepSpaceDot& operator=(DeepSpaceDot&& other) = default;
DeepSpaceDot& operator=(DeepSpaceDot&& other) = default;

~DeepSpaceDot() override;

Expand Down
2 changes: 1 addition & 1 deletion plugins/csp-trajectories/src/Trajectory.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ class Trajectory : public IVistaOpenGLDraw {
Trajectory(Trajectory&& other) = delete;

Trajectory& operator=(Trajectory const& other) = delete;
Trajectory& operator=(Trajectory&& other) = delete;
Trajectory& operator=(Trajectory&& other) = delete;

~Trajectory() override;

Expand Down
2 changes: 1 addition & 1 deletion plugins/csp-vr-accessibility/src/FloorGrid.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ class FloorGrid : public IVistaOpenGLDraw {
FloorGrid(FloorGrid&& other) = default;

FloorGrid& operator=(FloorGrid const& other) = delete;
FloorGrid& operator=(FloorGrid&& other) = delete;
FloorGrid& operator=(FloorGrid&& other) = delete;

~FloorGrid();

Expand Down
2 changes: 1 addition & 1 deletion plugins/csp-vr-accessibility/src/FovVignette.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ class FovVignette : public IVistaOpenGLDraw {
FovVignette(FovVignette&& other) = default;

FovVignette& operator=(FovVignette const& other) = delete;
FovVignette& operator=(FovVignette&& other) = delete;
FovVignette& operator=(FovVignette&& other) = delete;

~FovVignette();

Expand Down
4 changes: 2 additions & 2 deletions plugins/csp-wms-overlays/gui/js/csp-wms-overlays.js
Original file line number Diff line number Diff line change
Expand Up @@ -26,10 +26,10 @@

this._defaultBoundsLabel = document.getElementById("wmsOverlays-defaultBounds");
this._defaultBoundsGoTo = document.querySelector(
'[onclick="CosmoScout.callbacks.wmsOverlays.goToDefaultBounds()"]');
'[onclick="CosmoScout.callbacks.wmsOverlays.goToDefaultBounds()"]');
this._currentBoundsLabel = document.getElementById("wmsOverlays-currentBounds");
this._currentBoundsGoTo = document.querySelector(
'[onclick="CosmoScout.callbacks.wmsOverlays.goToCurrentBounds()"]');
'[onclick="CosmoScout.callbacks.wmsOverlays.goToCurrentBounds()"]');
this._currentBoundsUpdate =
document.querySelector('[onclick="CosmoScout.callbacks.wmsOverlays.updateBounds()"]');
this._currentBoundsReset =
Expand Down
6 changes: 3 additions & 3 deletions plugins/csp-wms-overlays/src/Plugin.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -542,7 +542,7 @@ void Plugin::onLoad() {
mWmsCreationThreads.at(settings.first).enqueue([this, settings, wmsUrl]() {
try {
WebMapService wms(wmsUrl, mPluginSettings->mUseCapabilityCache.get(),
mPluginSettings->mCapabilityCache.get());
mPluginSettings->mCapabilityCache.get());
std::unique_lock<std::mutex> lock(mWmsInsertMutex);
mWms[settings.first].push_back(std::move(wms));
} catch (std::exception const& e) {
Expand Down Expand Up @@ -607,8 +607,8 @@ void Plugin::setWMSServer(
std::shared_ptr<TextureOverlayRenderer> const& wmsOverlay, std::string const& name) {
auto& settings = getBodySettings(wmsOverlay);
auto const& server = std::find_if(mWms.at(wmsOverlay->getObjectName()).begin(),
mWms.at(wmsOverlay->getObjectName()).end(),
[&name](WebMapService const& wms) { return wms.getTitle() == name; });
mWms.at(wmsOverlay->getObjectName()).end(),
[&name](WebMapService const& wms) { return wms.getTitle() == name; });

if (server == mWms.at(wmsOverlay->getObjectName()).end()) {
if (name != "None") {
Expand Down
2 changes: 1 addition & 1 deletion plugins/csp-wms-overlays/src/WebMapService.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@ std::vector<WebMapLayer> const& WebMapService::getLayers() const {
std::optional<WebMapLayer> WebMapService::getLayer(std::string const& name) const {
std::vector<WebMapLayer> layers = getLayers();
auto layer = std::find_if(
layers.begin(), layers.end(), [name](WebMapLayer const& l) { return l.getName() == name; });
layers.begin(), layers.end(), [name](WebMapLayer const& l) { return l.getName() == name; });
if (layer == layers.end()) {
return {};
}
Expand Down
4 changes: 2 additions & 2 deletions resources/gui/js/apis/gui.js
Original file line number Diff line number Diff line change
Expand Up @@ -174,8 +174,8 @@ class GuiApi extends IApi {
* @see {initInputs}
*/
initDraggableWindows() {
const windows = document.querySelectorAll(".draggable-window");
var currentZIndex = 100;
const windows = document.querySelectorAll(".draggable-window");
var currentZIndex = 100;

windows.forEach((w) => {
// Center initially.
Expand Down
Loading

0 comments on commit af5b6c2

Please sign in to comment.