I don't know anything about JSpinner, and I really don't know what language this is in, but why not convert the string to an integer, use your first if statement, and in the else, divide by 100? Or did I just miss something in the translation here?
May also want to make sure the integer is positive before dividing by 100 (unless negative percentages are ok).