File tree Expand file tree Collapse file tree 2 files changed +2
-10
lines changed
Expand file tree Collapse file tree 2 files changed +2
-10
lines changed Original file line number Diff line number Diff line change @@ -852,10 +852,6 @@ bool Guider::MoveLockPosition(const PHD_Point& mountDeltaArg)
852852 }
853853
854854 const usImage *image = CurrentImage ();
855- if (!image)
856- {
857- throw ERROR_INFO (" cannot move lock pos without an image" );
858- }
859855
860856 // This loop is to handle dithers when the star is near the edge of the frame. The strategy
861857 // is to try reflecting the requested dither in 4 directions along the RA/Dec axes; if any
Original file line number Diff line number Diff line change @@ -452,7 +452,7 @@ bool GuiderMultiStar::AutoSelect(const wxRect& roi)
452452
453453 try
454454 {
455- if (!image || !image ->ImageData )
455+ if (!image->ImageData )
456456 {
457457 throw ERROR_INFO (" No Current Image" );
458458 }
@@ -519,7 +519,7 @@ bool GuiderMultiStar::AutoSelect(const wxRect& roi)
519519 error = true ;
520520 }
521521
522- if (image && image ->ImageData )
522+ if (image->ImageData )
523523 {
524524 if (error)
525525 Debug.Write (" GuiderMultiStar::AutoSelect failed.\n " );
@@ -1078,8 +1078,6 @@ bool GuiderMultiStar::SetLockPosition(const PHD_Point& position)
10781078bool GuiderMultiStar::IsValidLockPosition (const PHD_Point& pt)
10791079{
10801080 const usImage *pImage = CurrentImage ();
1081- if (!pImage)
1082- return false ;
10831081 // this is a bit ugly as it is tightly coupled to Star::Find
10841082 return pt.X >= 1 + m_searchRegion && pt.X + 1 + m_searchRegion < pImage->Size .GetX () && pt.Y >= 1 + m_searchRegion &&
10851083 pt.Y + 1 + m_searchRegion < pImage->Size .GetY ();
@@ -1088,8 +1086,6 @@ bool GuiderMultiStar::IsValidLockPosition(const PHD_Point& pt)
10881086bool GuiderMultiStar::IsValidSecondaryStarPosition (const PHD_Point& pt)
10891087{
10901088 const usImage *pImage = CurrentImage ();
1091- if (!pImage)
1092- return false ;
10931089 // As above, tightly coupled to Star::Find but with somewhat relaxed constraints. Find handles cases where search region is
10941090 // only partly within image
10951091 return pt.X >= 5 && pt.X + 5 < pImage->Size .GetX () && pt.Y >= 5 && pt.Y + 5 < pImage->Size .GetY ();
You can’t perform that action at this time.
0 commit comments