Skip to content

Commit

Permalink
Fix compiler warnings
Browse files Browse the repository at this point in the history
  • Loading branch information
wwmayer committed Jun 2, 2024
1 parent 859d47b commit 2671482
Show file tree
Hide file tree
Showing 5 changed files with 11 additions and 8 deletions.
2 changes: 1 addition & 1 deletion src/App/PropertyStandard.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -2840,7 +2840,7 @@ void PropertyMaterialList::setDiffuseColors(const std::vector<App::Color>& color
aboutToSetValue();
setSize(colors.size(), _lValueList[0]);

for (int i = 0; i < colors.size(); i++) {
for (std::size_t i = 0; i < colors.size(); i++) {
_lValueList[i].diffuseColor = colors[i];
}
hasSetValue();
Expand Down
4 changes: 2 additions & 2 deletions src/Gui/DlgMaterialPropertiesImp.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -229,7 +229,7 @@ void DlgMaterialPropertiesImp::onShininessValueChanged(int sh)
/**
* Reset the colors to the Coin3D defaults
*/
void DlgMaterialPropertiesImp::onButtonReset(bool checked)
void DlgMaterialPropertiesImp::onButtonReset()
{
for (std::vector<ViewProvider*>::iterator it = Objects.begin(); it != Objects.end(); ++it) {
App::Property* prop = (*it)->getPropertyByName(material.c_str());
Expand Down Expand Up @@ -257,7 +257,7 @@ void DlgMaterialPropertiesImp::onButtonReset(bool checked)
/**
* Reset the colors to the current default
*/
void DlgMaterialPropertiesImp::onButtonDefault(bool checked)
void DlgMaterialPropertiesImp::onButtonDefault()
{
for (std::vector<ViewProvider*>::iterator it = Objects.begin(); it != Objects.end(); ++it) {
App::Property* prop = (*it)->getPropertyByName(material.c_str());
Expand Down
5 changes: 3 additions & 2 deletions src/Gui/DlgMaterialPropertiesImp.h
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@
#include <QDialog>
#include <memory>
#include <vector>
#include <FCGlobal.h>

namespace App
{
Expand Down Expand Up @@ -63,8 +64,8 @@ class GuiExport DlgMaterialPropertiesImp: public QDialog
void onEmissiveColorChanged();
void onSpecularColorChanged();
void onShininessValueChanged(int);
void onButtonReset(bool checked);
void onButtonDefault(bool checked);
void onButtonReset();
void onButtonDefault();
void setButtonColors();

protected:
Expand Down
4 changes: 3 additions & 1 deletion src/Mod/Material/Gui/AppearancePreview.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -257,7 +257,9 @@ void AppearancePreview::setTexture(const QImage& image)
}

void AppearancePreview::setTextureScaling(double scale)
{}
{
Q_UNUSED(scale)
}

void AppearancePreview::resetAmbientColor()
{
Expand Down
4 changes: 2 additions & 2 deletions src/Mod/Material/Gui/MaterialsEditor.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -898,7 +898,7 @@ bool MaterialsEditor::updateTexturePreview() const
{
bool hasImage = false;
QImage image;
double scaling = 99.0;
//double scaling = 99.0;
if (_material->hasModel(Materials::ModelUUIDs::ModelUUID_Rendering_Texture)) {
// First try loading an embedded image
try {
Expand Down Expand Up @@ -939,7 +939,7 @@ bool MaterialsEditor::updateTexturePreview() const
try {
auto property = _material->getAppearanceProperty(QLatin1String("TextureScaling"));
if (!property->isNull()) {
scaling = property->getFloat();
//scaling = property->getFloat();
// Base::Console().Log("Has 'TextureScaling' = %g\n", scaling);
}
}
Expand Down

0 comments on commit 2671482

Please sign in to comment.