User Activity

void Screen2View::up1(){   if (buttonWithIcon1.getPressedState()==true) HAL_GPIO_WritePin(GPIOD, GPIO_PIN_6,GPIO_PIN_RESET);   else HAL_GPIO_WritePin(GPIOD, GPIO_PIN_6,GPIO_PIN_SET);}what is wrong, thans for help