When should "Don’t ask next time" check box take effect?

for example, suppose I have a popup like that:

enter image description here

I know the popup would not appear next time when the user clicks 'Yes' with the box checked.

but how about the following situations:

  1. the user clicks 'No' but 'Don't ask next time' checked
  2. 'Don't ask next time' checked but the application/windows closed

My question is: When should 'Don't ask next time' check box take effect?

  1. Take effect immediately (popup wouldn't show next time if box checked but the application/window closed)
  2. Take effect after 'Yes' or 'No' is selected
  3. Take effect only after 'Yes' is selected

which one should be used?