back to scratko.xyz
aboutsummaryrefslogtreecommitdiff
path: root/puzzle.hpp
diff options
context:
space:
mode:
authorscratko <m@scratko.xyz>2025-02-24 17:15:23 +0300
committerscratko <m@scratko.xyz>2025-02-24 17:15:23 +0300
commitac9a06b04144023e87d1a504cfe5598e7cf3d7b4 (patch)
treec7daf10b9f348551653e0459c1dfc86fdba0063d /puzzle.hpp
parent4f64ac2f9265fe216e8d62f0d73a6f3b3389fbb1 (diff)
downloadpicture-puzzle-ac9a06b04144023e87d1a504cfe5598e7cf3d7b4.tar.gz
picture-puzzle-ac9a06b04144023e87d1a504cfe5598e7cf3d7b4.tar.bz2
picture-puzzle-ac9a06b04144023e87d1a504cfe5598e7cf3d7b4.zip
Refactoring in classesHEADmaster
Moved friend declarations in classes
Diffstat (limited to 'puzzle.hpp')
-rw-r--r--puzzle.hpp9
1 files changed, 4 insertions, 5 deletions
diff --git a/puzzle.hpp b/puzzle.hpp
index 6e8d666..09660c8 100644
--- a/puzzle.hpp
+++ b/puzzle.hpp
@@ -58,11 +58,6 @@ private:
void CreateNewPuzzles();
void SelectRandomPicture();
Fl_PNG_Image *LoadPictureParts(std::unique_ptr<Puzzle>& tmp_puzzle);
-
- friend class PuzzleGame;
- friend class ASearch;
- friend void press_button_callback(Fl_Widget*, void*);
- friend void solve_problem_callback(Fl_Widget*, void*);
public:
void SetXYEmptyBox(int x, int y) { empty_box.x = x; empty_box. y = y; }
coordinates GetXYEmptyBox() { return empty_box; }
@@ -73,6 +68,10 @@ public:
gi->CalculateStandardPuzzlePos();
return gi;
}
+ friend class PuzzleGame;
+ friend class ASearch;
+ friend void press_button_callback(Fl_Widget*, void*);
+ friend void solve_problem_callback(Fl_Widget*, void*);
};
#endif