isPortraitLandscape method
@Description check if the current context is with portrait and landscape view @Return: bool => bool check for this condition
Implementation
bool isPortraitLandscape(){
if(context == null && currentMaxWidth != null){
final bool check = currentMaxWidth! >= this.minWidth;
bool otherCheck = true;
if(this.maxWidth != -1)
otherCheck = currentMaxWidth! <= this.maxWidth;
return check && otherCheck;
}
else if(context != null && currentMaxWidth == null){
return context!.size!.width >= this.minWidth && context!.size!.width < this.maxWidth;
}
else{
return false;
}
}