Button press and hold/ double press and hold

J-M-L:
you need to write a state machine (and consider debouncing)

im already using state machine for long/short button presses but now im trying to figure out my first question.

  if (button.currentState != button.prevState) {
    button.currentState = digitalRead(button.pin);
    if (button.currentState == PRESSED) {
      button.counter = millis();
    }

    if (button.currentState == NOT_PRESSED) {

      unsigned long currentMillis = millis();
      if ((currentMillis - button.counter >= shortPress) && !(currentMillis - button.counter >= longPress) ) {

        handleShortPress();
      }
      if ((currentMillis - button.counter >= longPress)) {

        handleLongPress();
      }
      if ((currentMillis - button.counter >= UltraPress))

        handleUltraPress();
    }

    button.prevState = button.currentState;
  }