Unfortunately, you can't do such things... this would be too easy 
First, about this kind of code (without using i18n):
variable_get('uc_variable', t('Something'));
It will work as the variable is not initialized (ie not stored in the 'variable' table). Once the form (where the variable is used) is submitted, the provided default value will be ignored "forever", and so it will break translation.
IMHO, you can safely remove those t().
With i18n :
I examined the i18n code and realized that if a variable is initialized, its content will be shown in the multilingual textfield.
In the previous test, I had to type 'Add to cart' again, just because 'uc_product_add_to_cart_text' had not been stored yet.
So, first solution would be :
- Explicitly sets those variables during installation(in 'ubertcart.profile'). For instance:
variable_set('uc_product_add_to_cart_text','Add to cart'); - add the
$conf['i18_variables']in settings.php
This way, if the site in monolingual and not english, users will have to translate those textfields.
If the site is multilingual, users only have to install i18n, and translate textfields (which will be populated with the values set during install process).
Then, we could do a little better, by using the 'st' function :
variable_set('uc_product_add_to_cart_text', st('Add to cart'));
This would improve the monolingual case : variables initial values could be translated via .po files.
Will test the latter and report...
